General :  K-Meleon Web Browser Forum
General discussion about K-Meleon 
forum posting/BB code editing
Posted by: gdv
Date: January 20, 2009 06:32AM

Some of you may recall from my first question about 3 weeks ago, that I'm completely new to KM as well as BB Code.

Well, I tremendously appreciate everyone's help, but I'm realizing that it's taking WAY too much time to post my questions and replies, especially with complicated questions and the need to format quotes from earlier in the thread to keep it all tied together.

Often it has seemed better to compose/edit in an external editor, with a larger window and more flexibility than the forum post editor, and then copy/paste into the forum editor. But then I have to manually insert the BB code in the external editor or insert it later within the forum editor. Pretty unwieldy... sad smiley

Some of you that post MANY entries every day must have a better way. How do you do it?

Is there some kind of text editor (preferably freeware/open source) that is specifically set up to use BB code?

Sign me... ...drowning in forum posting process (or maybe just too old to keep up!)

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 20, 2009 10:20AM

I think that we can extended JujuLand's KmSmiley macro to add all BB codes in selection text context menu. This can do more easy post in forum.

K-Meleon in Spanish

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: disrupted
Date: January 20, 2009 03:43PM

http://www.autohotkey.com/forum/topic6161.html
(requires autohotkey for execution/compiling)

there is indeed a compiled version.. i just launch the script with ahk



Edited 1 time(s). Last edit at 01/20/2009 03:47PM by disrupted.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: disrupted
Date: January 20, 2009 04:27PM

macro to launch bbcode editor from the text contextmenu when editing in forum boxes etc


# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)

# --------- BB EDITOR -----------
#
# Dependencies :
# Resources : -
# Preferences : -
#
# -------------------------------------------------------
# ----- PRIVATE

BBedit{
macroinfo = "Forum BBeditor";
exec("I:\\applications\\editors\\bbcode\\compiled\\BBCodeWriter.exe");
}


BBedit_BuildMenu{
setmenu("TextPopup",macro,"Forum BB editor",BBedit);
}

$OnInit=$OnInit."BBedit_BuildMenu;";

# ----------------------------------------------------------
$macroModules=$macroModules."BBedit;";


(change path in red to where votre bbcodewriter.exe is installed)

edit: when bbwriter is launched from km macro it might display an error.. to fix this: copy bbcodewriter.ini and customtags.ini into kmeleon's folder



Edited 1 time(s). Last edit at 01/20/2009 05:41PM by disrupted.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: gdv
Date: January 21, 2009 07:08AM

@disrupted

Thanks!

The AHK stuff is over my head (have wanted to learn scripting and AHK, but think I'd need some hands-on guidance). But I've downloaded and will check out the compiled version!

Edit: BTW, in addition to the forum link provided earlier by disrupted, there is a nice one page description/guide on the AHK BBCodeWriter v.7.0 homepage.



Edited 2 time(s). Last edit at 01/21/2009 07:34AM by gdv.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 22, 2009 06:44PM

This macro can help you with BBcode:
KmBBcode.kmm

-EDITED:
I forget said how work:

Right click in forum post text box for smileys and horizontal line, showed in "Smileys" context submenu.

With selected text, right click in forum post text box for "BBcode" context submenu with all BBcode options to apply to selected text.

K-Meleon in Spanish



Edited 3 time(s). Last edit at 01/22/2009 08:30PM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 22, 2009 08:01PM

A good thing to add ought to be an accel to open the sub menu.

When writing a post it would be easier not to take the mouse to do it.

Unfortunately, I haven't found a way to do it with macros.

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 22, 2009 08:24PM

You can do it in macros, add a accel wit setaccel("Showmenu") function and call a function with a rebarmenu("menuName") called.

You can show some example in this old posts.

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/22/2009 08:28PM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 23, 2009 04:33PM

It seems it doesn't work, here are the modifications I have made in KmSmiley.kmm:

__Smile{
setmenu("TextPopup",popup,"&Smileys");
setmenu("&Smileys",macro,"Drool",__drool);
setmenu("&Smileys",macro,"Cool",__cool);
setmenu("&Smileys",macro,"Mad",__mad);
setmenu("&Smileys",macro,"Sleepy",__sleepy);
setmenu("&Smileys",macro,"Sad",__sad);
setmenu("&Smileys",macro,"Smile",__smile);
setmenu("&Smileys",macro,"Big grin",__biggrin);
setmenu("&Smileys",macro,"Surprised",__surprised);
setmenu("&Smileys",macro,"Tongue",__tongue);
setmenu("&Smileys",macro,"Confused",__confused);
rebuildmenu("&Smileys");
alert("Here we go","");
}

_Smileys_BuildMenu{
#setmenu("TextPopup",popup,"&Smileys");
#setmenu("&Smileys",macro,"Drool",__drool);
#setmenu("&Smileys",macro,"Cool",__cool);
#setmenu("&Smileys",macro,"Mad",__mad);
#setmenu("&Smileys",macro,"Sleepy",__sleepy);
#setmenu("&Smileys",macro,"Sad",__sad);
#setmenu("&Smileys",macro,"Smile",__smile);
#setmenu("&Smileys",macro,"Big grin",__biggrin);
#setmenu("&Smileys",macro,"Surprised",__surprised);
#setmenu("&Smileys",macro,"Tongue",__tongue);
#setmenu("&Smileys",macro,"Confused",__confused);
setaccel("CTRL ALT *","macros(__Smile)");
}

I have tried with setmenus in buildmenu and in smile. The same. Alert is just here to see if setaccel works.

if in smile, it add another &Smileys entry ... but never opens the popup menu.

I think it's impossible, else if we were able to generate keystrokes.

Setaccel, for me, works only for menu entry, not to pop up a menu.

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 23, 2009 04:47PM

This is possible, please, read the link to old post in my post above.

1) Note that i talk about rebarmenu() plugin function not rebuildmenu() macro function.

2) When you indicated in setaccel() function "CTRL ALT *" , note that this * key is in keyboard, not numpad, in numpad is represented by VK_MULTIPLY.

If you wait to tomorrow i like rewrite my KmBBcode.kmm macro code and add this functionality.

K-Meleon in Spanish

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 23, 2009 05:08PM

Quote

1) Note that i talk about rebarmenu() plugin function not rebuildmenu() macro function.

Line 247 rebarmenu() : undefined function

Quote

2) When you indicated in setaccel() function "CTRL ALT *" , note that this * key is in keyboard, not numpad, in numpad is represented by VK_MULTIPLY.

Yes, I have forgotten to add the second setaccel

Quote

If you wait to tomorrow i like rewrite my KmBBcode.kmm macro code and add this functionality.

Ok, I'll wait ...

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 24, 2009 08:54PM

I rebuilded my KmBBcode.kmm.

Note this at the end of code:
#setaccel("CTRL K",plugin(rebarmenu, "BBcode_AM"));
#For accelerator add a similar line to this in Edit -> Configuration -> Accelerators
#CTRL K = rebarmenu(BBcode_AM)

In macros rebarmenu plugin not work, this plugin only work in accel.cfg file for accelerators.
His sentence in macros should be similar to this:
setaccel("CTRL K",plugin(rebarmenu, "BBcode_AM"));
But i don't sure, I'll checked rebarmenu plugin source.

- EDITED: Read my post bellow, right code line is;
setaccel("CTRL K","rebarmenu(BBcode_AM)");

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/24/2009 11:20PM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 24, 2009 10:02PM

@desga,

You seem to arrive to the same conclusions than me : it doesn't work ...

Ok, now, no more errors, but it does nothing.

Another reason which makes me not the way used (accel.cfg) is to have to modify it ... not easy to make it in setup, and to unsetup.

The better thing that Dorian ought to do for us, is to add an popmenu() function to popup an existing menu, with perhaps some controls (toç define) not to open everything everywhere...

Just a remark : You ought to add a separator between
and the smileys, else I like the bbcode functions.

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: guenter
Date: January 24, 2009 10:43PM

Smilies are updated AFIK by disrupted.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 24, 2009 11:04PM

Sorry I'm wrong this work now: KmBBcode.kmm
smiling smiley
You must use this code line:
setaccel("CTRL K","rebarmenu(BBcode_AM)");

Ctrl+K open popup menu.
Line BBcode item moved to BBcode menu (isn't a smiley).
Added the code to MacroLibrary.

K-Meleon in Spanish



Edited 2 time(s). Last edit at 01/24/2009 11:45PM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 25, 2009 10:06AM

@desga,

ok, now it works, but with a little problem.

Smiley or bbcode menu entries are twice, in right-click menu or in accel popup.

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: January 25, 2009 10:34AM

Quote
JujuLand
@desga,

ok, now it works, but with a little problem.

Smiley or bbcode menu entries are twice, in right-click menu or in accel popup.

A+

This isn't a problem this is a feature. smiling smiley
You can access to menu items from popup menu accel or with right click context menu.

If you like use only one way you can comment unlike setmenu() lines in code.
For example, if you like only popup menu:
_BBcode_BuildMenu{
#Text box context menu:
#setmenu("TextPopup",separator,-1);
#setmenu("TextPopup",popup,"&Smileys",-1);
...
#Selection context menu:
#setmenu("Selection",popup,"&BBcode",-1);
...

Is it you like?

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/25/2009 10:34AM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: JujuLand
Date: January 25, 2009 07:38PM

No, it was not this.

I had two menu entries with the name &Smileys and two menu entries with &BBcode.

Now, curiously, it's ok ...

It was perhaps an effect of whisky or pastis smiling smiley

A+



Mozilla/5.0 (x11; U; Linux x86_64; fr-FR; rv:38.0) Gecko/20100101 Ubuntu/12.04 K-Meleon/76.0


Web: http://jujuland.pagesperso-orange.fr/
Mail : alain [dot] aupeix [at] wanadoo [dot] fr



Ubuntu 12.04 - Gramps 3.4.9 - Harbour 3.2.0 - Hwgui 2.20-3 - K-Meleon 76.0 rc



Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: siria
Date: September 12, 2009 01:35PM

Thanks for the macro, it's nice! I only have a little problem:

I'd also like to shorten menu names, the way it's explained here:
http://kmeleonbrowser.org/forum/read.php?1,74662,74662#msg-74662
Quote

F&av{
!F&avorites
}

!Main{
-F&avorites
:F&av
}
And that just wouldn't work on my ancient system, as so many things, argh!! Then after much searching around finally figured out it only doesn't work if this macro is enabled. Being a clueless end user, I looked at the macro and took a wild guess that this rebarmenu-thing could sound suspicious, then looked what happens when disabling this line:
# setaccel("CTRL K","rebarmenu(BBcode_AM)");

Now the smileys still work fine with a right-click, and the Fav-menu is short, but the bbcode has completely vanished.
Isn't there a way to have both, changeable menu names and bbcode-macro...?



Edited 1 time(s). Last edit at 09/12/2009 01:46PM by siria.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: desga2
Date: September 12, 2009 05:16PM

Yes, you found a problem between rebarmenu and rename menu config options.
This is because rebarmenu plugin reload original menu instead changed menu in KM user profile.

BBcode is showed in right click menu only if you have some selected text.

Commented this line is right because it only disable CTRL+K accelerator:
# setaccel("CTRL K","rebarmenu(BBcode_AM)");

Reported Bug # 1147

K-Meleon in Spanish



Edited 3 time(s). Last edit at 09/12/2009 05:37PM by desga2.

Options: ReplyQuote
Re: forum posting/BB code editing
Posted by: siria
Date: September 13, 2009 09:19PM

Oops... Thanks desga!! You're right, it works, I only had forgotten the text selection first Wasn't the first time so I should have remembered, but after messing with the macro I thought immediately that had been the reason. Oh well.

Anyway, great that it works! :-))

Options: ReplyQuote


K-Meleon forum is powered by Phorum.