General :  K-Meleon Web Browser Forum
General discussion about K-Meleon 
Pages: Previous123Next
Current Page: 2 of 3
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Mala Okeh
Date: January 14, 2008 02:22PM

Hi! Thx for the excellent beta3 version. Two things I would like to install for myself:

* a button to read mail
* to change the notebook button that opens default notepad to open another notebook such as metapad a.o.

Would be great if anyone could help me.

Thx in advance,

Mala Okeh

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 14, 2008 05:30PM

Quote
Mala Okeh
* a button to read mail
* to change the notebook button that opens default notepad to open another notebook such as metapad a.o.

A) I need worked a little in it. I like add mail options to Preference panel.

cool smiley It's easy, you only open 'notes.lua' file (in 'lua' folder) with notepad (or similar) and change the line:
notepad = "notepad.exe"
to your executable path program: (note that '\' character must be double)
notepad = "C:\\Example\\path\\powernotes.exe"

Tip: With the line:
name = "notebook.txt",
You can change filename used to notes.

K-Meleon in Spanish

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Mala Okeh
Date: January 14, 2008 06:45PM

Thx, desga2, the change of the notepad.exe into another .exe works great (I forgot to put doubled \ in my own previous attempts). I am curious to see your solution for the mail.

Mala Okeh

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3 desga2 Edition
Posted by: desga2
Date: January 18, 2008 01:08AM

Hi everybody,

I upload to my web a 7zip file with a patch to K-MCCF ME 0.08, i named it 'desga2 Edition'. This is a recopilation of errors and bugs fixed by me. A lot of this fixed are in this thread. To install it copy the files in each folder and overwrite the old files.

IMPORTANT NOTE: If you make changes in your originals files you must a backup of files that you will overwrited. Else you can lost your modifications.

List of changes & fixeds:

<> In preferences panel i changed Avanced tab to subs:
Area Code -> Notes application path
Cyberarticle path -> Mail client path

+ Added better notes macro with application path configuration and modificated notes functions to read application preference without restart.
+ Added mail option in menu, mail lua macro and configuration to mail client path in preference panel.

- Deleted Weather Report and Area Code in menus, macros and preferences.
- Deleted Cyberarticle references in all lua macros and preferences.

+ Added a mail button in toolbar. (toolbars.cfg file to default skin Silverbird)
+ Implemented Freedom button concept included, no strict toolbars definitions!
(All buttons are independent)

^ Better preference panel GUI, texts and boxes definitions.
! Fixed some preference panel strings and definitions in locals.lua.
+ Created menu access to config files: menus, accel.cfg, toolbar.cfg, prefs.js and kmeleon.js (in edit.lua file). You can found in 'Options' -> 'Advanced configs' menu.
+ Added 'About plugins' in 'Help' menu. And others abouts changeds.
^ Updated UserAgent strings.


Download link:
http://two.xthost.info/kmeleon/patchs/KM-CCF08_desga2_Edition.7z

I hope this changes like you, and Hao can added it in next version.

K-Meleon in Spanish



Edited 2 time(s). Last edit at 01/18/2008 03:23PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Hao Jiang
Date: January 18, 2008 04:39AM

@desga2,

Thank you very much for your work and great patch you make! Hope everyone will like it. The mail function and freedom button concept are very nice.

Regards,

Hao

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: ACM
Date: January 18, 2008 02:16PM

So no one will tell desga2 that the link above does not work? Wanna a free, no ads free host that really works? Try this: http://www.110mb.com

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 18, 2008 03:42PM

Quote
ACM
So no one will tell desga2 that the link above does not work? Wanna a free, no ads free host that really works? Try this: http://www.110mb.com

Thanks for your hosting recomendation, i'll considered to change.
But the problem is the php forum URL link conversion:

With [ url = ...] example link [ / url ] notation:
example.url

I have used [ b ]& [ / b ] to link showed good.
www.example.url

PHP forum URL links conversion not run fine. sad smiley

Edited: Curiosity in the 'Preview' of the post the link is showed good.

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/18/2008 03:46PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: ACM
Date: January 18, 2008 05:00PM

I am sorry to report that the new edited link does not work also. I even tried to download the file with another browser, but it failed as well. Another host recommendation could be http://megashare.com/ .

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 18, 2008 08:02PM

@ ACM:

Link is downloaded ok to me in FireFox 2.0.0.11 and K-Meleon 1.1.x. I checked the download file and this is correct.

What browser and version are you using?
Are you using some download manager?

Only you have this problem, Hao downloaded the file ok.

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/18/2008 08:03PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: ACM
Date: January 18, 2008 08:34PM

I guess there is some misundersting going on here. On my part, mind you. I expected 4/5 MB file, but I got just a mere 2 KB one. I failed to notice this is just a patch, not the complete browser bundle or a new, full variant compilation of the whole source code of K-Meleon. I am really sorry and beg your pardon, although allow me to reassert that the original link was indeed broken.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 18, 2008 09:21PM

No problem, rigth is a PATCH file with 23 KB of size.
smiling smiley

K-Meleon in Spanish

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Arrow
Date: January 19, 2008 02:43AM

Great!

Thank you very much desga2.



Edited 1 time(s). Last edit at 01/19/2008 02:47AM by Arrow.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Mala Okeh
Date: January 19, 2008 07:09AM

Thx, desga2. Your patch works allright to me. Thx for the mail button.

Mala Okeh

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: ACM
Date: January 19, 2008 10:47AM

Would a search Favorites function be hard to code? That's quite handy and would be much appreciated by many users, I guess.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 19, 2008 02:07PM

Quote
ACM
Would a search Favorites function be hard to code? That's quite handy and would be much appreciated by many users, I guess.

Are you referer to Favorites (IE) or Bookmarks?

K-Meleon in Spanish

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 19, 2008 02:59PM

Is there an easy way to put items from the preference drop down list back on the Toolbar area like "File, View, Edit, etc.?

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: ACM
Date: January 19, 2008 03:19PM

desga2,

I used "Favorites" as a generic term. Sorry. In fact, I mean K-meleon bookmarks (our "Favorite" addresses bookmarked in K-Meleon).

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 19, 2008 04:59PM

Quote
Zoohooter
Is there an easy way to put items from the preference drop down list back on the Toolbar area like "File, View, Edit, etc.?

To show menu bar go to Preference panel (click in Preference button) and in first tab 'Display' check 'Show Menu' option. You need restart K-Meleon to view changes.

This option will changed the pref value:
user_pref("kmeleon.toolband.Menu.visibility", false);
to
user_pref("kmeleon.toolband.Menu.visibility", true);
in your 'pref.js' file in your K-M user profile:

K-Meleon in Spanish



Edited 2 time(s). Last edit at 01/19/2008 05:04PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 19, 2008 05:50PM

Thanks for the quick reply:-)

Options: ReplyQuote
Example to add a Lua macro in menu.
Posted by: desga2
Date: January 19, 2008 06:46PM

Example: Add a menu item to open an Instant Messenger.

To change menus you must modify 'menus.cfg' file. You can found this file in path:
C:\K-MeleonCCFME0.08Beta3\pref\menus.cfg
If you have installed my patch, see before posts in this thread, you can acces to this file from menu: Options -> Advanced Configs -> Menus

- Documentation about menus definitions:
http://kmeleon.sourceforge.net/wiki/ConfigFiles#menus
http://kmeleon.sourceforge.net/manual/menus-cfg.html
http://freenet-homepage.de/CoolMcKluus/software/kmeleon/project/reference/cfgfiles/menus.html

In last link of documentation, the section "Advanced menu configuration" don't work in CCF versions.

Note that in CCF version is used luamacro() instead macro().

Example code to 'menus.cfg' file: (added code in bold)

E&xternal{
luamacro(externalexec("C:\Program Files\MSN Messenger\msnmsgr.exe"), Open MSN Messenger)
}

Main {
:&File
:&Edit
:&View
%ifplugin bookmarks
:&Bookmarks
%endif
%ifplugin favorites
:F&avorites
%endif
%ifplugin hotlist
:H&otlist
%endif
:&Options
:&Proxy
:Groups
%ifplugin sessions
:&Sessions
%endif
:&Help
:E&xternal
bmpmenu(top)
}

- Documentation about Lua language:
English: http://www.lua.org/manual/5.1/
Spanish: http://www.lua.org/manual/5.1/es/
Portuguese: http://www.lua.org/manual/5.1/pt/

- Documentation, plugin for K-Meleon and others tools:
Mark307's web page (creator of Lua plugin for K-Meleon):
http://mark307.hp.infoseek.co.jp/

First you must add this line in 'macros.lua' file to load new macro file:
require "external"
'external' is the name (without extension) of Lua macro file ('external.lua', in this example).
'macros.lua' file is in path: C:\K-MeleonCCFME0.08Beta3\pref\macros.lua

Example code to Lua macro file 'external.lua':
--[[
Filename: external.lua
This is a lua macro to exec an external application method.
By: desga2

Note to load macro and this work:
Needed add this line in 'macros.lua' file at path: C:\K-MeleonCCFME0.08Beta3\pref\
require "external"

Example to use in 'menus.cfg':
luamacro(externalexec("C:\full\path\to\filename.exe"), Open external application)
]]

function externalexec(path)

	if path then
		exec(path)
	end

end

Remember save changes in all files and restart K-Meleon CCF.
Now you have a new menu item to open your Instant Messenger: (in this example)
External -> Open MSN Messenger

Good coding!

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/21/2008 12:02AM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 22, 2008 07:21PM

Another question? Is there a way to add a Java Script on/off button on the Toolbar? tia

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: guenter
Date: January 22, 2008 07:37PM

no, but right click on privacy options button will give you that toogle as option.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 22, 2008 07:57PM

You can add an accelerate key as for example F7, in 'accel.cfg' file:
VK_F7 = luamacro(JSToggle)

K-Meleon in Spanish

Options: ReplyQuote
Example: Java Script on/off button on Toolbar
Posted by: desga2
Date: January 22, 2008 10:49PM

--[[
Filename: JSToggleB.lua
This is a lua macro to checked/unchecked (on/off) button in toolbar,
as for example a JavaScript button.
By: desga2
Based on: http://kmeleonbrowser.org/forum/read.php?1,76210,76238#msg-76238

Note to load macro and this work:
Needed add this line in 'macros.lua' file at path: C:\K-MeleonCCFME0.08Beta3\pref\
require "JSToggleB"

Example code to use it in 'toolbars.cfg':
JSButton Bar(16,16){
	JSButton{
	luamacro(ToggleJS)
	JavaScript Toggle
	toolhot.bmp[19]
	toolcold.bmp[18]
	tooldead.bmp[19]
	}
}
]]

-- Main function:
function ToggleJS()

	JSToggle()
	_pref_SyncJavaScript()

end

-- Toolbar syncronization:
function _pref_SyncJavaScript()
-- JSButton Bar (make sure the toolbar name is correct):
	toolbar_name="JSButton Bar"
	if getpref(TYPE_BOOL, "javascript.enabled")==false then
		v_button=1
	elseif getpref(TYPE_BOOL, "javascript.enabled")==true then
		v_button=0
	end
	pluginmsg("toolbars","CheckButton",toolbar_name..",luamacro(ToggleJS)"..","..v_button)
end

-- Load button state when start:
hook.add(StartupHook, _pref_SyncJavaScript)
hook.add(LoadHook, _pref_SyncJavaScript)
hook.add(ActivateWindowHook, _pref_SyncJavaScript)

eye rolling smiley Good coding my friends!

K-Meleon in Spanish

Options: ReplyQuote
Re: Example: Java Script on/off button on Toolbar
Posted by: guenter
Date: January 22, 2008 11:52PM

Quote
desga2
[/code]

eye rolling smiley Good coding my friends!

Holla desgas2, Your contribution from ES was kind of late grinning smiley plus tongue sticking out smiley

it takes contributions from ES, JP, CN, FR... to code cool browsers such as k-meleons smiling smiley

For more smilies C desgas2's post in here




Edited 2 time(s). Last edit at 01/22/2008 11:59PM by guenter.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 23, 2008 04:26PM

Thanks for the reply. Is this supposed to work? I followed the above instructions and when I open KM I get the following error msg:

...Program Files\K-MeleonCCFME0.08Beta3\pref\macros.lua:40: module 'JSToggleB' not found:
no field package.preload['JSToggleB']
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\lua\JSToggleB.lua'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\lua\JSToggleB.lc'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\pref\\lua\JSToggleB.lua'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\pref\\lua\JSToggleB.lc'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\lua\JSToggleB.lua'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\lua\JSToggleB.lc'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\pref\\lua\JSToggleB.lua'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\pref\\lua\JSToggleB.lc'
no file 'C:\Program Files\K-MeleonCCFME0.08Beta3\pref\\lua\JSToggleB.dll'

what am I doing wrong?

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: desga2
Date: January 23, 2008 05:32PM

Code in post before must be in a text filenamed 'JSToggleB.lua' as you can read at begining of code:
Quote
In my code
Filename: JSToggleB.lua
This file must be stored in 'lua' folder in your K-M CCf installation path, for example: C:\K-MeleonCCFME0.08Beta3\lua\
In this folder are all .lua files, your problem can be two things:
A) You saved code in a file with other filename or extension.
cool smiley You saved the file in an incorrect folder. (not in \lua folder)

When you add this code line in 'macros.lua' file:
Quote
In my code
Needed add this line in 'macros.lua' file at path: C:\K-MeleonCCFME0.08Beta3\pref\
require "JSToggleB"

You are says to K-M CCF "Search me this file 'JSToggleB' and load it (.lua is added automaticaly) that must be in '\lua' folder", but in your case, K-M CCF not found your file.
Check if your inserted line code in 'macros.lua' is identical filenamed to filename (and the correct extension .lua) with all code in before post.

Check it and try again! tongue sticking out smiley
The error message is clear: "module 'JSToggleB' not found"

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/23/2008 05:37PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 23, 2008 07:30PM

Aha! there is a button on the toolbar titled "Javascript Toggle", unfortunately, clicking on it does nothing :-( . I placed the script in the "Silverbird" toolbars.cfg since that is the skin I use. Is this correct? and if not, where should it be placed? tia

Options: ReplyQuote
How to run my script code before to childs
Posted by: desga2
Date: January 23, 2008 08:23PM

@ Zoohooter:

Sorry but my patience is exhausted, i'm going to tell it as if you are a child of 6 years. tongue sticking out smiley

-1) Copy this post and before post with all code in some temp text file. Use notepad or similar! (Rigth click -> New -> Text Document)

0) Close K-MeleonCCF. NOW!

1) Add this code in 'toolbars.cfg' file at your current used skin, for example to 'Silverbid': C:\K-MeleonCCFME0.08Beta3\skins\Silverbird\toolbars.cfg
JSButton Bar(16,16){
	JSButton{
	luamacro(ToggleJS)
	JavaScript Toggle
	toolhot.bmp[19]
	toolcold.bmp[18]
	tooldead.bmp[19]
	}
}
Save changes and close.

2) Add this line in 'macros.lua' file at path: C:\K-MeleonCCFME0.08Beta3\pref\
require "JSToggleB"
For example you can add it at end of 'require "******"' line list (after last line or in middle of list where you like). Save changes and close.

3) Open windows explorer, go to your K-MeleonCCF install folder and go to \lua subfolder in it. Example path: C:\K-MeleonCCFME0.08Beta3\lua\

4) Create a new text file. (you know, yes? Rigth click -> New -> Text Document)
And rename it to JSToggleB.lua

5) Open your new file JSToggleB.lua with notepad or similar and paste all code in before post. Save changes and close.

6) Run K-MeleonCCF and there is a new icon in toolbar!
PUSH IT! Work, PUSH IT AGAIN! WORK!
Good job boy.

I hope you don't get angry with me. smiling smiley

P.S.; When it work is showed in status bar the message "JavaScript ALLOWED/BLOKED"
(When you push in button, obviously)
If this not work you are a bad boy. Read this again but now with more attention because you are doing something bad.

K-Meleon in Spanish



Edited 1 time(s). Last edit at 01/23/2008 08:24PM by desga2.

Options: ReplyQuote
Re: K-MeleonCCF ME 0.08 Beta3
Posted by: Zoohooter
Date: January 23, 2008 08:40PM

Problem solved, works great!!! Thank you very much :-)

Options: ReplyQuote
Pages: Previous123Next
Current Page: 2 of 3


K-Meleon forum is powered by Phorum.