Improvement requests :  K-Meleon Web Browser Forum
Use this forum to talk about a feature you're missing. 
Pages: 12Next
Current Page: 1 of 2
Some questions, requests
Posted by: c-sanchez
Date: January 14, 2015 10:59PM

IMHO I think it is better that adjustments of "Links meant yo open a New windows" and "URLs passed from external applications" are default "In new tab" instead of" In a new windows".

I wonder if there is way to "remove" the title bar of the window of k-meleon so that it get a little more of screen space, Like Chrome or current versions of Firefox.
I know it could do something similar with fullscreen and display the taskbar.
But what I wonder is whether you can do something "native"
Some time ago try to do something similar, Making the buttons Minimize, Restore / Maximize and Close through the macros, But I could only make the close button, because I did not see anything to create the other two tongue sticking out smiley
So the idea was simply to put it in full screen and display these three buttons on the title bar, and leave taskbar visible ofcourse.

I also wonder if there is something similar to the "Bin trash" of closed tabs of Opera on K-Meleon.

Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 14, 2015 11:41PM

Sounds familiar...
There were macros a few years ago playing with title bar, but I think it's a native pref now in newer KM versions? Just not sure where to find it - in F2 somewhere? In about:config? Look around a bit ;-)

As for the window buttons, there sure are macros out there among the hundreds. For myself I once added just a couple lines to the skin config manually. If you like and still use the OLD skin configuration, edit the active toolbars.cfg and just copy those lines near the end or top.
Of course You'll also need icons. What I did is make screenshots of my normal window buttons and saved as bmp into the skins default folder, back when it was still usable for default icons smiling smiley
Would attach mine here, but they are awfully plain and ugly from win98.

And yes, in times of tiny flat screens I agree it would make sense to include such a mini toolbar out of the box. First hidden of course, instead of the hidden privbar tongue sticking out smiley

(tested in KM1.6 ;-)
add in active toolbars.cfg (with notepad or better notepad++ etc.)
Quote

#=======================================================
# WINDOWSIZE
#=======================================================
# Buttons are normally by default in each window titlebar, just in case the titlebar is hidden with some macro:

Window Size(16,16){
Minimize Window{
ID_MINIMIZE_WINDOW|Toolbars
Minimize Window
windowsize.bmp[0]
windowsize.bmp[0]
}
Toggle Window{
ID_TOGGLE_WINDOW|New
Toggle Window
windowsize.bmp[1]
windowsize.bmp[1]
}
Close Window{
ID_FILE_CLOSE|CloseWindow
Close Window
windowsize.bmp[2]
windowsize.bmp[2]
}
}



Edited 1 time(s). Last edit at 01/15/2015 09:17PM by siria.

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 15, 2015 01:00AM

Quote
c-sanchez
I also wonder if there is something similar to the "Bin trash" of closed tabs of Opera on K-Meleon.

I don't know anything about Opera, but if "Bin trash" means a way to re-open previously closed tabs, then perhaps this can help.

https://dl.dropboxusercontent.com/u/1522294/PriorTabs.kmm

It is a macro which adds an item under the view menu which will allow a previously closed tab to be re-opened.

Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 15, 2015 10:23AM

Yep, nice macro smiling smiley

Quote

exec("cmd /c ERASE \"".$_PriorTabs_Path."\"");
## For user of win9x operating systems, cmd should be replaced with Command in the above line

"%COMSPEC%..." used to work like "cmd" and "command" in newer and older systems alike, but it's been awhile. Just curious, would that still work in your win7 too? Or anyone can try in 8.1?

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 15, 2015 01:51PM

Quote
siria
"%COMSPEC%..." used to work like "cmd" and "command" in newer and older systems alike, but it's been awhile. Just curious, would that still work in your win7 too? Or anyone can try in 8.1?

Yes, it works in Win 7. It still causes a flash of the command window so I actually use another method on my personal copy.

pluginmsg(utils, "unlink", $_PriorTabs_Path);
#exec("cmd /c ERASE \"".$_PriorTabs_Path."\"");
#exec("%COMSPEC% /c ERASE \"".$_PriorTabs_Path."\"");

Utils unlink does not cause a flash. It is not for novice users as most other functions in utils fail.

%COMSPEC% is a good piece of information to know. Thanks.

Options: ReplyQuote
Re: Some questions, requests
Posted by: c-sanchez
Date: January 15, 2015 03:52PM

Thank you very much for the response siria, JamesD.

where you have to put PriorTabs.ini?

the menu Clear List work, but not the list. instead of saving the list of closed tabs, show only ... in his stead.

Here a picture of "Bin trash" of Otter Browser
http://s23.postimg.cc/iacn4xsg7/otter_tabs.jpg

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 15, 2015 07:05PM

Quote
c-sanchez
where you have to put PriorTabs.ini?

the menu Clear List work, but not the list. instead of saving the list of closed tabs, show only ... in his stead.

The priortabs module is only for collecting and retaining tabs closed in the current session of KM. The ini file is automaticly created in your profile.

The clear list function just wipes out the ini and let's the user begin collecting closed tabs from that point onward.

Is your goal to retain closed tabs between sessions?

Edit:
After I posted, I opened and closed several tabs and took this screenshot.





Edited 1 time(s). Last edit at 01/15/2015 07:24PM by JamesD.

Options: ReplyQuote
Re: Some questions, requests
Posted by: c-sanchez
Date: January 15, 2015 08:39PM

mmm I not understand, does not work as in your image sad smiley
as I said, this shows "..."

maybe because I'm using Windows XP? confused smiley



Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 15, 2015 09:06PM

Quote
JamesD
Yes, it works in Win 7. It still causes a flash of the command window so I actually use another method on my personal copy.

Utils unlink does not cause a flash.

Not quite sure if I fully understand, that probably means that "cmd" flashes too and only "utils" does not?

c-sanchez, just wondering, if you look inside the ini with an editor during the session, does it contain a list of URLs?

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 15, 2015 11:51PM

I will go and check to see that the version on the server is correct.

Edit: Big oops on my part. I had wrong version in previous post.

Please try this one.

https://dl.dropboxusercontent.com/u/1522294/PriorTabs.7z

Edit2:

Not yet, there is still a problem.



Edited 2 time(s). Last edit at 01/16/2015 12:25AM by JamesD.

Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 16, 2015 12:24AM

LOL, what is it today? First dorian, now you - who next, perhaps me? grinning smiley

But this version can't work without utils, if I read that right...

(PS: really no need for credits just for one little word ;-)

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 16, 2015 01:02AM

This version does not need utils. I have re-tested several times.

The utils statements are commented out and replaced by %COMSPEC%.

I had forgot that utils was in there twice.

I think it is possible to get a false reading depending on the url and title of the website. I saw a "..." one time but could not make it happen again.


https://dl.dropboxusercontent.com/u/1522294/PriorTabs.7z

Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 16, 2015 08:35AM

The header still lists utils as required...
Of course I took a curious look at the code too, but must admit your variable names are so long and unintuitive my graycell RAM keeps overflowing and had to give up ;-)

But in line 143 that should be a 6, and line 147 I don't understand at all, but contains those "..."
Surprised to see rebuildmenu, never could figure out what that command is good for or how it works, always had thought it doesn't do anything at all.

I had some major struggles too with own macros containing urls and titles in a menu, and there were some issues needing replacements, but been too long, would have to research again for details. Dimly guess " and or commas... But your code is different, may not need it, am not sure.



Edited 1 time(s). Last edit at 01/16/2015 10:32AM by siria.

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 16, 2015 09:01PM

@ siria

I am having major struggles too. The code is old and my memory makes Swiss cheese look solid.

I don't think the "clear" is working right in the last version posted.

I found a version that I distributed with 1.6 beta 2.6 that seems to work. My next move is a line by line compare. I will have a look at your suggestions also.

I used to keep two versions. One for public ( no utils ), and one for me using utils. Now with %COMSPEC%, I hope to get one version that works.

$kUtils ? pluginmsg(utils, "unlink", $_PriorTabs_Path) : exec("%COMSPEC% /c ERASE \"".$_PriorTabs_Path."\"");


Options: ReplyQuote
Re: Some questions, requests
Posted by: soccerfan
Date: January 17, 2015 04:34PM

Quote
JamesD
...My next move is a line by line compare...

You may want to try examdiff (free version) from here:
http://www.prestosoft.com/edp_examdiff.asp
I have used version 1.8 (no install zip) in the past.

soccerfan

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 18, 2015 02:32PM

I think this version will correctly clear a current list if needed.

https://dl.dropboxusercontent.com/u/1522294/PriorTabs.7z

It was a problem with the order of operations and reseting a counter that caused a problem in the earlier copy.

Options: ReplyQuote
Re: Some questions, requests
Posted by: c-sanchez
Date: January 19, 2015 02:14AM

I do not understand, still does not work prior tabs in k-meleon 75.
I need download some file in addition to the macro?



Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 19, 2015 09:12AM

No there are no additional files needed. Although the optional utils.dll would make the deletion of the ini-file smoother, but that has nothing to do with menu lines.

No idea why this dot-thing happens exactly, and I do not see those dots in the menu myself, but get the correct titles shown. Perhaps it depends from KM75, no idea, or perhaps it just depends on the title and URL of the stored page itself, due to length or special characters.

Gave it a shot too yesterday, first just meaning to simplify the code for easier readability, but then as usual couldn't resist and rewrote the whole thing in my own usual coding styles ;-) The menu stuff is much shorter in that version, and I boldly threw out the whole module block to rebuild a menu list from the stored ini-list, which is unnecessary anyway. That function would only be needed at browser startup, but at this point the old list shall always be deleted first. And this block also contained that ...-line. Wondering if this version would work better with your pages now or if it's just KM75 or if problematic pages may now simply produce another error. Could try to upload it later this evening if thats okay. Meanwhile you could test if closing pages in this forum also produces dots.

But unfortunately found one general bug that James and I have no chance to work around, as hobby macrocoders: When background tabs are closed, e.g. by middle-clicking on a tab, then the URL of the current active page is stored instad sad smiley
And the same prob hits when opening a stored session, which means KM first closes the current session by itself and is closing all except the current page as background tabs. Making macros think all closed pages had only this 1 URL.

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 19, 2015 12:32PM

@ c-sanchez & siria

Please make sure that you have the latest code. It should contain this line.
# Updated             : 1.6 2015-01-18 ( fix clearlist order of operations & counter reset )

Are you seeing only the "..." or only seeing them after a clear list operation. My testing has been under KM 75 b2.

Siria is right in that tabs closed during a window close will not be captured. It all has to do with KM's event order.

KM reports to macro system that a window with tab(s) is closed in this order.

OnCloseWindow
OnCloseTab ( one or more times )

I think the tabs should close first and then the window.

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 19, 2015 05:54PM

@ c-sanchez

Perhaps I have not asked the right question. The priortabs.ini file is supposed to be created in your UserMacro folder. With KM running, and after closing a tab in the current window, use EDIT > CONFIGURATION > PROFILE DIRECTORY to open your profile. One of the folders there should be named 'macros'. Open that folder and confirm that you have a file named 'PriorTabs.ini'. The file should contain records like the one below.


Options: ReplyQuote
Re: Some questions, requests
Posted by: siria
Date: January 19, 2015 06:53PM

Yeah that's what I wondered too, if that ini-file exists at all and if yes, what it contains. High chance it's just a missing writing permission again, as usual.

Your macro does and did work fine on my machine, James smiling smiley
Just don't manage to decipher the code, which of course doesn't matter, as long as it works. It makes it more difficult though to hunt down probs like this one - except if the ini file is plain missing due to system permissions.

Options: ReplyQuote
Re: Some questions, requests
Posted by: JamesD
Date: January 20, 2015 12:58AM

I think that I have found the problem. I had the ini file being created in the UserMacroFolder. Even if the user has writing permission to his/her profile the directory named 'macros' must exist. The PriorTabs.kmm file does not create that directory. Therefore if the user has put PriorTabs.kmm in root\macros it will run but unless the user creates a 'macros' folder in the profile the ini is not created.

I have updated PriorTabs.kmm here:
https://dl.dropboxusercontent.com/u/1522294/PriorTabs.7z

This version writes the ini file directly to the profile.

@ c-sanchez
You did ask before and I just did not pick up on the significance of your question.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: siria
Date: January 20, 2015 07:31PM

@c-sanchez To quote myself:
Quote
siria
No there are no additional files needed. Although the optional utils.dll would make the deletion of the ini-file smoother, but that has nothing to do with menu lines.

Sorry, meanwhile it dawned on me, that sounds misunderstandable.
To make it clearer:
- For installation there is NO additional file needed (only the kmm)
- the closed page adresses are stored inside an ADDITIONAL file in the user profile, but this ini-file gets automatically created by the macro at each browser start (and deleted again when the browser is closed)

When you open the menu and click at one of the closed pages, the macro gets only a hidden counter number for the page adress, for example "closed tab no.3", regardless what the menu line displays as text. Then it looks up that number in the ini-file with the stored adress list and gets address no.3 (or whatever).

So to figure those dots out, it would be important to know whether this auto-created ini-file really gets created or not, on your machine??
Under some circumstances (no write permission or no folder) the creation doesn't work.
If that file does exist, does it contains the page adresses?
If both is okay, what happens when you click on those dots in the menu?



Edited 2 time(s). Last edit at 01/20/2015 07:46PM by siria.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: JamesD
Date: January 21, 2015 02:31AM

I did a test using PriorTabs. I opened a second window and in that window, I opened second tab. I closed the tabs one at a time. Of course when I closed the last tab, that closed the window also.

From the remaining window I ran PriorTabs and I had two entries in the list. The name of the first tab closed was there but the second entry was just '...'.

At the current coding level, PriorTabs cannot obtain the last tab in a window.

Edit:
I must have closed one tab and then closed window. Closing the last tab in a window does not actually close the tab. The tab just changes to "about:blank".



Edited 1 time(s). Last edit at 01/21/2015 12:55PM by JamesD.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: siria
Date: January 21, 2015 06:18PM

Quote
JamesD
Closing the last tab in a window does not actually close the tab. The tab just changes to "about:blank".

Good catch! Can confirm: neither onclosetab nor onclosewindow is fired in that case, and it makes sense.

I know it's just a setting if a user wants to jump to about:blank or not, so it may not affect everyone, but for the many others this tab adress is lost. Although I had already added priortabs to onclosewindow too, this specific case is lost, *unless* I remember to NOT close the last tab via tab, but via window-X.

But sadly I'm finding more and more little flaws in this whole nice concept :-/ Not only are closed background tabs lost, and multi-tabs in a closed window (must test again), but also the tab-history on restored tabs. The native function in the sessions menu can only restore the last tab, but this one comes together with its whole history back. Will add that native function to my custom priortabs-menu.



Edited 1 time(s). Last edit at 01/21/2015 09:10PM by siria.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: siria
Date: January 21, 2015 09:15PM

Siiigh... can't believe it, swiss cheese memory, although I've used that function daily, for years!! Of course the native function can restore MULTIPLE last tabs too! Just haven't found a menu for it yet, so can only open them one by one, in reverse order as they were closed.
And in the menu Sessions/Options one can set the number of max undo-closed.

Now wondering if it would be hard to improve the sessions plugin, so it offers a menu too...



Edited 1 time(s). Last edit at 01/21/2015 09:35PM by siria.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: c-sanchez
Date: January 21, 2015 11:07PM

Good JamesD!
Now prior-tabs works perfectly grinning smiley
excellent macros that you do for k-meleon ^^
Excuse my delay in responding.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: JamesD
Date: January 22, 2015 01:28AM

@ siria

I don't use sessions very much, but I do have the 'sessions(Undo)' as the action for button on my main toolbar.

Also I hide the tab bar when there is only one tab so I will likely change the outcome for closing the last tab. When I am down to one tab I only see the window. I don't even see the tab buttons.

I need to do some coding/testing and some may not work until Dorian makes his change.

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: JamesD
Date: January 22, 2015 01:35AM

Quote
c-sanchez
Now prior-tabs works perfectly grinning smiley
excellent macros that you do for k-meleon ^^

Thank you, but I hope to make it better. Right now the closing of the last tab in a window is not captured. See this thread:
http://kmeleonbrowser.org/forum/read.php?3,131710,131743#msg-131743

Options: ReplyQuote
Re: PriorTabs macro (open last closed pages)
Posted by: rodocop
Date: January 27, 2015 06:06PM

One worthwhile observation:

when you get tab back with PriorTabs - it resurrects by its own, without its browsing history.

on the contrary, 'Undo Last Closed' built-in option reloads old tab with all the 'back' steps saved.

Options: ReplyQuote
Pages: 12Next
Current Page: 1 of 2


K-Meleon forum is powered by Phorum.