New Plugin - Customize Toolbar

dave-user
2011-06-05
2013-11-17
<< < 1 2 3 > >> (Page 2 of 3)
  • Anonymous - 2012-09-17

    If better, the toolbar could show the status.

    e.g., if I set "Always on Top" or "Read-only" on toolbar, if the toolbar could show icon according to current status, it should be great!

     
  • dave-user

    dave-user - 2012-09-17

    If I want to add a new button, e.g., explorer button, the command would like below:

          Run,Open containing folder,,,notepad++.bmp

    but how do I know which icon name to set for it?

    When using the Custom Buttons feature, you must create your own icon in a .bmp file. The .bmp icon file must be an image of 16x16 pixels with a bit depth of 8-bits. Any pixels that are the same colour as the first pixel will appear transparent.

    The .bmp icon file must be placed in the same folder as the .btn configuration file.

    I would recommend upgrading to Customize Toolbar 3.1, in which case, the .btn configuration file must employ Unicode UTF-16 little endian encoding, with or without a Byte Order Mark (BOM) at the start of the file.

    Regards,

    Dave

     
  • dave-user

    dave-user - 2012-09-17

    If better, the toolbar could show the status.

    e.g., if I set "Always on Top" or "Read-only" on toolbar, if the toolbar could show icon according to current status, it should be great!

    I agree that this would be a nice feature, and it is something I looked at when developing Customize Toolbar 3.0 & 3.1, but unfortunately I can't see a way of doing this at present.  I will keep it in mind for a future version.

    Regards,

    Dave

     
  • Anonymous - 2012-09-17

    I agree that this would be a nice feature, and it is something I looked at when developing Customize Toolbar 3.0 & 3.1, but unfortunately I can't see a way of doing this at present.  I will keep it in mind for a future version.

    Regards,

    Dave

    Thanks for your quick reply and great plugin. Waiting to hear good news :)

     
  • Moon

    Moon - 2012-10-04

    Cool plugin thanks, but I can't figure out why my TextFX buttons don't appear.

    Here is my CustomizeToolbar.btn…

    Edit,Select All,,,
    TextFX,TextFX Settings,Help,,
    TextFX,TextFX Tools,Sort lines case insensitive (at column),,
    TextFX,TextFX Tools,T:Sort lines case insensitive (at column),,
    Plugins,Converter,About,,
    

    The first and last buttons appear on the toolbar, but the 3 TextFX ones don't.
    (I tried the T: variant because that's how it appears in the ShortCut Mapper).

    Please could someone give me a hint?

    Kind regards,
    Moon

     
  • Glyph

    Glyph - 2012-10-04

    @sandymoon: Maybe if you but the multiple-word-strings into quotes? Like TextFX,"TextFX Tools","Sort lines case insensitive (at column)",,?

    I can't try myself because whatever I do I don't see any custom buttons. The menu item is checked, the file CustomizeToolbar.btn exists but no buttons anywhere. What should happen? Should the buttons appear in the Customize menu of Customize Toolbar?

     
  • dave-user

    dave-user - 2012-10-05

    Hi sandymoon,

    This is an interesting problem.  After quite a lot of investigation, it turns out the problem is caused by the order in which the various plugins receive notifications from Notepad++.  Because Customize Toolbar is alphabetically ahead of TextFX, it receives notifications prior to TextFX.  In this particular case, it means that the TextFX menu does not exist on the Notepad++ menu bar, when Customize Toolbar scans for it.  This would not happen for every plugin that is alphabetically after Customize Toolbar, it just depends when the plugin adds its menu (i.e. which notification it uses as the trigger).

    Anyway there is a very simple workaround.  Open the plugins folder where the "CustomizeToolbar.dll" file is located and rename the file to "ZCustomizeToolbar.dll".  Everything should then work fine.

    I will investigate if there is a better solution, and then release a new version of Customize Toolbar that resolves this problem.

    Regards,

    Dave

     
  • Moon

    Moon - 2012-10-05

    Thanks Dave for the prompt investigation - glad I'm not going mad. I do like a quick'n'dirty workaround - confirmed working.

    @Uninfected:
    Thanks for suggestion - turns out the quotes are not required though.

    The buttons in CustomizeToolbar.btn just appeared for me at the end of the toolbar (with a hammer icon), and so also at the end of the "Current toolbar buttons" list in the Customize Toolbar dialog.

    I suggest testing with default CustomizeToolbar.btn - rename your existing one and then toggle off then on the "Plugins -> Customize Toolbar -> Custom Buttons" option. Then exit Notepad++ and restart.

    The first line of the default CustomizeToolbar.btn is :

    Edit,Select All,,,selectall.bmp
    

    This just worked first time for me - do you have the "Edit -> Select All" menu option in Notepad++ (v6.1.8).

     
  • Glyph

    Glyph - 2012-10-05

    Thanks sandymoon, got it working now.

    My fault: I tested with the English commands in the CustomizeToolbar.btn but I use np++ with a German localization.
    Now I am using the localized strings and it works

     
  • Glyph

    Glyph - 2012-10-05

    One more question:
    is there a way to access items that are not on the menus?
    I tried to switch themes with a custom button, e.g.

    Settings,Style Configurator,Select theme,Choco,
    

    but that doesn't work because the last two aren't commands from the menu.

     
  • dave-user

    dave-user - 2012-10-05

    Hi uninfected,

    It is not possible to access items that are not on the menus.  However, you can create a custom button to open the Style Configurator window, with the following entry:

    Settings,Style Configurator...,,,
    

    You should be able to create custom buttons for any menu item that directly initiates an action, whether on a Notepad++ standard menu or a menu added by a plugin.

    Regards,

    Dave

     
  • Glyph

    Glyph - 2012-10-05

    Ok, thanks.

     
  • Jan Schreiber

    Jan Schreiber - 2012-10-12

    I'm using version 3.1 of this excellent plugin and experiencing an issue lately. This is what my CustomizeToolbar.btn file looks like:

    Erweiterungen,Squiggly Spell Check,Auto Spell Check,,abc.bmp
    Erweiterungen,Task List,Show Task List,,tasklist.bmp
    

    Only the first button is displayed on the toolbar. Additionally, the custom icon isn't used, but the hammer appears instead. Any thoughts?

     
  • dave-user

    dave-user - 2012-10-12

    The first thing to try is renaming the "CustomizeToolbar.dll" to "ZCustomizeToolbar.dll".

    If this doesn't work, then I have a few questions:

    1.  Is your .btn file Unicode UTF-16 encoded?   If not, you can you use normal Notepad to change this with File > Save As > Encoding > Unicode.

    2.  Which folder are your .bmp icon files located in?  They must be in the same folder as the .btn file.

    3.  Are your .bmp icon files 16 x 16 pixels with a bit depth of 8-bits?

    4.  What happens if your reverse the order of the two entries?

    Regards,

    Dave

    .

     
  • Jan Schreiber

    Jan Schreiber - 2012-10-13

    Thanks for your patience, Dave. Upon closer inspection it turned out that my .btn file had mixed line endings for some reason: partly Windows and partly UNIX. After converting the line endings to Windows, the custom icons show up as expected. Problem solved!

    One minor thing remains on my wishlist though: When playing around with the custom icons, it was a welcome surprise that the icon with the wavy red underline in the second row below correctly reflects the status of the Squiggly plugin on a per-file basis. I cannot say the same of the custom icon in the first row (fifth from the right): It toggles the status of "show spaces and tabs", but the status of the icon does not visually reflect the status of the toggle.

     
  • dave-user

    dave-user - 2012-10-17

    https://www.google.com/accounts

    If better, the toolbar could show the status. e.g., if I set "Always on Top" or "Read-only" on toolbar, if the toolbar could show icon according to current status, it should be great!

    Customize Toolbar 3.2 has just been released.

    In this version of Customize Toolbar, the checked states (depressed or not) of all toolbar buttons are now synchronized with the checked states (ticked or not) of the corresponding menu items.  This also works for user-defined custom buttons.

    Hope you like it.

    Regards,

    Dave

     
  • dave-user

    dave-user - 2012-10-17

    janschreiber

    One minor thing remains on my wishlist though: When playing around with the custom icons, it was a welcome surprise that the icon with the wavy red underline in the second row below correctly reflects the status of the Squiggly plugin on a per-file basis. I cannot say the same of the custom icon in the first row (fifth from the right): It toggles the status of "show spaces and tabs", but the status of the icon does not visually reflect the status of the toggle.

    Customize Toolbar 3.2 has just been released.

    In this version of Customize Toolbar:

    - The checked states (depressed or not) of all toolbar buttons are now synchronized with the checked states
         (ticked or not) of the corresponding menu items. This also works for user-defined custom buttons.

    - The 'Custom Buttons' feature now always works with menu commands in other plugins, including the TextFX plugin.
       The workaround (renaming the .dll file to ZCustomizeToolbar.dll) is no longer necessary.

    Hope you like it.

    Regards,

    Dave

     
  • Jan Schreiber

    Jan Schreiber - 2012-10-20

    Awesome! The new 3.2 version works just as advertised. I love it.

     
  • Glyph

    Glyph - 2012-10-20

    Where can I get 3.2?
    Shouldn't the update work with the update mechanism of the plugin manager? The plugin manager says 3.1 is the latest version.

     
  • Dave Brotherstone

    @uninfected - I'm doing the update as we speak, it should be available within an hour or so.

     
  • Glyph

    Glyph - 2012-10-20

    Arrived *thumbs up* :-) Thanks

     
  • Glyph

    Glyph - 2012-10-21

    I see a weird effect with the TextFX-Items when used in the CustomizeToolbar.btn:

    This is the far right end of the toolbar before adding custom buttons:

    I added three buttons like this:

    TextFX,TextFX Tools,Sort lines case insensitive (at column),,sort.bmp
    Einstellungen,Stile ...,,,stile.bmp
    TextFX,TextFX Quick,Mark to matching {([<Brace>])},,braces.bmp
    

    Closing/reopening of np++ gets me this which is the intended look:

    This works fine as log as I am not moving something  on the toolbar. I chose "Customize…" and move the heart button three steps to the right. After closing and reopening np++ I get a doubled button. It does what the original buttons does but i doesn't have a tooltip:

    In my tests this happened only with TextFX-items.
    I made sure that all three items have a CR|LF at the end and the file is encoded correctly.
    (If you try to reproduce that remember that the second item is localized and must be changed to something like "Settings,Style Configurator…,,,stile.bmp)

     
  • Glyph

    Glyph - 2012-10-21

    Regarding the above post please take the first line of code to the last position.  My fault when pasting, pity that I can't edit in these forums.

     
  • Dex

    Dex - 2013-03-05

    I wanted to say thanks for making this plugin, I find it very convenient.

    Also thanks to the posters in this thread.
    I was having issues getting some custom buttons to work. It turns out I had multiple things wrong that previous posts (especially the comment about somehow having mixed line endings) pointed out to me. I now have all of my custom buttons working.
    -Dex

     
  • Yaron

    Yaron - 2013-05-08

    Thank you for a great plugin.

    If I set a custom icon to a command which already has an icon, the custom image only sticks for the session (i.e. the original image reappears on the next startup).

    I’d be grateful for a solution.

     
<< < 1 2 3 > >> (Page 2 of 3)

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks