Laycat: simple picker for layouts and catalogs
-
- Posts: 1075
- Joined: 30 May 2008 21:02
- Location: Lake Erie
Re: Laycat: simple picker for layouts and catalogs
Since Filehero gave Laycat to the world it has become a much used CTB. Then when Columns was added thought - to use an old TV tagline - "It just don't get no better". Now if klownboy melds Toolbars into the script will need to find some new superlative to cover what by any reasonable definition is a utility that is an adjunct to XY.
Re: Laycat: simple picker for layouts and catalogs
I finally gave this Toolbar addition to Filehero's LayCat enough testing on 2 computers to where I'm satisfied to post. It should look like my earlier post on June 28, 2014. This script (LayCatTools.xys) will give you the option to load and save toolbars in addition to the catalog, layouts, and column layouts on Filehero's script. I also included save menu items for the layouts and catalog.
Please do not create a folder called toolbars off the <xydata> folder. Why? Because this script will do that on it's first run and at the same time, it will then save the "current" toolbar you're using in that folder. So you should see it in the Toolbar section of the menu. The "current" or last accessed toolbar will be flagged as you can see. If your computer does not display the symbols as shown in my image, you may have to change them to something more standard (e.g., and asterisk, a dash extra, etc.). Always have an updated backup of XYplorer.ini as a pre-caution.
Please let me know if you experience any issues. I've included the icons shown in the image which are not XY's built-in ones, but you'll to update the icon/icon locations within the script. Just play around and save a new toolbar...and then see how fast and seemless it is to change toolbars. Don should really build it in to XY.
Thanks Filehero for the nice script and letting me toy with it a little. Thanks to Sammay for your help with "last accessed" file and also to Stefan for all his previous work with Toolbars (I mentioned his posts earlier in this thread). I may include rename and delete options later, but for now you can simply go to the folder and rename delete any toolbars or layout you want since they're just text files.
Ken
Please do not create a folder called toolbars off the <xydata> folder. Why? Because this script will do that on it's first run and at the same time, it will then save the "current" toolbar you're using in that folder. So you should see it in the Toolbar section of the menu. The "current" or last accessed toolbar will be flagged as you can see. If your computer does not display the symbols as shown in my image, you may have to change them to something more standard (e.g., and asterisk, a dash extra, etc.). Always have an updated backup of XYplorer.ini as a pre-caution.
Please let me know if you experience any issues. I've included the icons shown in the image which are not XY's built-in ones, but you'll to update the icon/icon locations within the script. Just play around and save a new toolbar...and then see how fast and seemless it is to change toolbars. Don should really build it in to XY.
Thanks Filehero for the nice script and letting me toy with it a little. Thanks to Sammay for your help with "last accessed" file and also to Stefan for all his previous work with Toolbars (I mentioned his posts earlier in this thread). I may include rename and delete options later, but for now you can simply go to the folder and rename delete any toolbars or layout you want since they're just text files.
Ken
Last edited by klownboy on 01 Jul 2014 12:46, edited 1 time in total.
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440
Re: Laycat: simple picker for layouts and catalogs
Hahaha! I have to admit that too. I don't plan on retiring those 2 scripts yet. They're still too awesome in many ways. Layout manager especially since I can easily switch to different layouts depending whether I want to view pictures (needs lots of space) or file managing (need lots of info and stuff all over the place). Session Manager is too awesome as well.klownboy wrote:Thanks Filehero, I'm not planning on retiring your Layout Manager or Session Manager just yet though. One is a right click of a CTB and the other the left.
Ken
That however does not mean I won't add this script to my use.
Thanks!
@ Klownboy
Just to note but on line 135, you still have the icons being referenced to:
"Save Toolbar|D:\Graphics\Icons\Combined\Customize Toolbar on.ico";
rather than:
"Save Toolbar|<xyicons>\Customize Toolbar on.ico";
Re: Laycat: simple picker for layouts and catalogs
Hi Enternal, on my system I do actually have a few folders off of my the main <xyicons> folder which is "D:\Graphics\Icons" , one being "Combined" (for combined 16 and 24 size icons). I had that folder for icons long before XY so I changed the XY pointer for <xyicons> to that folder since many other programs used that folder as well. I'll change it to simply <xyicons> for the posted version though so I don't confuse people making tweaks to the icons and locations.Enternal wrote:Just to note but on line 135, you still have the icons being referenced to:"Save Toolbar|D:\Graphics\Icons\Combined\Customize Toolbar on.ico";rather than:"Save Toolbar|<xyicons>\Customize Toolbar on.ico";
Let me know if you have any issues.
Thanks,
Ken
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440
Re: Laycat: simple picker for layouts and catalogs
Hi, there's a comment about XY auto-picking single-item menus. I'd like to mention that I've generally gotten around this issue by adding a separator to the menu ( XYskinner adds one by default, but a more sensible approach is a conditional separator added only when menu items are < 2)
Icon Names | Onyx | Undocumented Commands | xypcre
[ this user is asleep ]
[ this user is asleep ]
Re: Laycat: simple picker for layouts and catalogs
@ Filehero & klownboy
I borrowed your script to make it display PaperFolders. Saves 2 extra clicks instead of the usual 4 using Don's menu. Heh.
I borrowed your script to make it display PaperFolders. Saves 2 extra clicks instead of the usual 4 using Don's menu. Heh.
Code: Select all
$ICO_LAYOUT = "<xyicons>\Layout_01.ico";
$DISASTER_MSG = "You don't have at least one saved Paper Folder!<crlf><crlf>Quiting now.";
$DIR_PAPER = "<xydata>\Paper";
// Gather menu entries
$Papers = "";
//Layout section: Prepare list from files names of saved layouts
If (Exists($DIR_PAPER) == 2) {
$Papers = ListFolder($DIR_PAPER, "*.txt", 5);
$Papers = Replace($Papers, ".txt", "");
}
// Exit if nothing is to pick
If (!$Papers) {
Msg($DISASTER_MSG);
End(1);
}
// Build and assemble menu
$Papermenu = "";
If ($Papers) {
Foreach ($Item, $Papers, "|") {
$Papermenu = $Papermenu . " * $Item"<crlf>;
$Papermenu = $Papermenu . " Goto paper:$Item;<crlf><crlf>";
//$Papermenu = $Papermenu . " PaperFolder(""$Item"", , , "l");<crlf><crlf>";
}
$Papermenu = """PAPERS|$ICO_LAYOUT""" . ";" . "<crlf>" . "$Papermenu";
}
$MScript = $Papermenu;
$MScript = $MScript;
Load($MScript, , s);
Re: Laycat: simple picker for layouts and catalogs
Enternal wrote:@ Filehero & klownboy
I borrowed your script to make it display PaperFolders. Saves 2 extra clicks instead of the usual 4 using Don's menu. Heh.
Cool, I like choices and flavors.
Cheers,
Filehero
Re: Laycat: simple picker for layouts and catalogs
@Enternal, yes, that is cool. I'm tempted to build it into the LatCatTool menu so they're all together, but possibly it would make it too long especially for smaller displays when someone has a bunch of menu items.
Thanks,
Ken
Thanks,
Ken
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440
Re: Laycat: simple picker for layouts and catalogs
Yeah I think it might be better to be separate since it's not really related to layouts anyway. Anyway, fixed a couple more things, add ability to delete Paper Folders directly without navigating to the folder!, use a different method that was recently fixed by Don, and some other things I forgot. Kind of fun messing with it actually. Had an issue with heredoc not taking "<crlf>" as a literal even when I was using single quotations. Wonder how I can get that to work.klownboy wrote:@Enternal, yes, that is cool. I'm tempted to build it into the LatCatTool menu so they're all together, but possibly it would make it too long especially for smaller displays when someone has a bunch of menu items.
Thanks,
Ken
Code: Select all
$Savemen = <<<SAV
"Toggle Paper Folder|:paper" #778;
"Delete Paper Folder|:del" InputSelect("Paper Folder".'<crlf>'."Select to Delete:", "$PapersFile");
SAV;
$MScript = $Savemen;
Load($Savemen, , s);
- Attachments
-
- PaperList.xys
- (1.28 KiB) Downloaded 280 times
Re: Laycat: simple picker for layouts and catalogs
Great script - more comfort than the "real" thing - except for the right-click options (Allow Zombies etc). Is there a way to attach those to the CTB's right-click?
Re: Laycat: simple picker for layouts and catalogs
I don't know yet. Those other options that I used were used just because they were actually under the Menu items so that means they have command IDs I could use. For the zombies, not so much.Stef123 wrote:Great script - more comfort than the "real" thing - except for the right-click options (Allow Zombies etc). Is there a way to attach those to the CTB's right-click?
Re: Laycat: simple picker for layouts and catalogs
@Enternal - Not sure I understand. Let me put it another way, as a more generic question: Is there a way to assign the existing right-click menu of a built-in TB button to the the right-click action of my CTB?
I have learned to assign the XY left-click to my right click via "button "paper"
But how do I bring in the XY right-click?
I have learned to assign the XY left-click to my right click via "button "paper"
But how do I bring in the XY right-click?
Re: Laycat: simple picker for layouts and catalogs
Oh! Sorry I misunderstood you. I thought you meant adding the ability to toggle the "Allow Zombies" setting for papers in the script.Stef123 wrote:@Enternal - Not sure I understand. Let me put it another way, as a more generic question: Is there a way to assign the existing right-click menu of a built-in TB button to the the right-click action of my CTB?
I have learned to assign the XY left-click to my right click via "button "paper"
But how do I bring in the XY right-click?
As to the answer you're actually looking for is: I don't think so. Although that does seem like a nice feature if you can assign the output of the built in toolbar menus into a custom toolbar. In this case, it would save an extra space.
Re: Laycat: simple picker for layouts and catalogs
button "paper", 2Stef123 wrote:I have learned to assign the XY left-click to my right click via "button "paper"
But how do I bring in the XY right-click?
Re: Laycat: simple picker for layouts and catalogs
Funny, I asked the same question here http://www.xyplorer.com/xyfc/viewtopic. ... 35#p107371and the answer from Sammay was, "you can use chr(13) instead of <crlf>, which seems to survive". He was absolutely correct. In my case with "LayCatTools", I didn't need the problem line in the heredoc so I didn't need to use it in the final script but I did test it and it does work - it does survive.Enternal wrote:Had an issue with heredoc not taking "<crlf>" as a literal
Stef123, yes, just was the button command with button name and then "2" for right click (e.g., button "minitree", 2;) and put that in the right click for the CTB. For the name use the abbreviated name in [brackets] as shown in Customize Toolbar, fp for Floating Preview
Ken
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440