Post Reply 

Color menuitems in script or plugin

Sep 15, 2014, 05:10
Post: #1
Color menuitems in script or plugin
Would like to be able to color red specific menuitems of some of my most used for easy find.

Is there a way to add
color: red !important;
into a script or plugin for only that specific script/plugin menuitem.
Thankyou.
Find all posts by this user
Quote this message in a reply
Sep 15, 2014, 06:23
Post: #2
RE: Color menuitems in script or plugin
Oh... so disappointed.
Well the keyboard shortcut thing doesn't work for me, too difficult to remember them and the easy "short" shortcuts I have already assigned for most important tasks that are not scripts/plugins.

Hoping in a future version some method for the specific menuitem coloring will be possible.

Thankyou ofnuts
Find all posts by this user
Quote this message in a reply
Sep 15, 2014, 08:09 (This post was last modified: Sep 15, 2014 08:49 by rich2005.)
Post: #3
RE: Color menuitems in script or plugin
No colour, but you could maybe create a bespoke menu item for your most favourite scripts, .scm or .py which are text. Compiled plugins not so easy. Maybe a second one for next favourite.

Use a decent text editor, find existing menu entry, duplicate it, then edit it, then comment (#) out the original. Important to keep the indents (spacing) the same as the original.

Here are 2 scm's and 2 .py's in a new drop down.

[Image: fRGIP7p.jpg]

Code:
examples

#(script-fu-menu-register "script-fu-auto-rotate" "<Image>/Layer" )
(script-fu-menu-register "script-fu-auto-rotate" "<Image>/Favourites/Auto-Rotate" )

or

#  menu="<Image>/Filters/Enhance",
  menu="<Image>/Favourites/Enhance",

If you try this, avoid duplicated scripts and edit, then try one at a time. Mistakes are very easy to make.

** https://www.gimp-forum.net/ now answering questions**
Find all posts by this user
Quote this message in a reply
Sep 29, 2014, 09:17 (This post was last modified: Sep 29, 2014 11:56 by paynekj.)
Post: #4
RE: Color menuitems in script or plugin
It is possible to highlight menuitems but you can't do it in a individual script, you have to make/alter the theme you are using:    

Here I have created a new theme, where the gtkrc file is only the following code, so that most of the styling is kept as the default, only very specific things are changed:
Code:
style "my_important"
{
  font_name = "sans bold 9"
  fg[NORMAL]        = "red"
}

style "my_ignore"
{
  fg[NORMAL]        = "yellow"
}

widget "GtkWindow.*.script-fu-drop-shadow.GtkAccelLabel" style:highest "my_important"
widget "GtkWindow.*.plug-in-nova.GtkAccelLabel" style:highest "my_important"

widget "GtkWindow.*.plug-in-gflare.GtkAccelLabel" style:highest "my_ignore"

I've been writing a guide to creating themes over on GimpChat: http://gimpchat.com/viewtopic.php?f=23&t=10531

Kevin
Find all posts by this user
Quote this message in a reply
Sep 29, 2014, 09:51
Post: #5
RE: Color menuitems in script or plugin
(Sep 29, 2014 09:30)ofnuts Wrote:  I've read the GC topic and don't see how you assign specific styles to specific menu entries?

That's because I haven't explained it yet Smile

Having just done it here, I'll add the explanation later today with more details about how you can use wildcards to style collections of items (script-fu, plugins, my own scripts etc) although I've no doubt you can look at my post above and work it out for yourself.

Kevin
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Any plugin for open multiple image in paint.net shinprog 1 325 Oct 31, 2017 11:38
Last Post: paynekj
  plugin save for web in Gimp 2.9.6 Dkk 1 191 Oct 19, 2017 09:02
Last Post: paynekj
  Request for script chlebna 1 171 Sep 13, 2017 09:35
Last Post: ythgilb
  Request for script - Guillotine + Watermark sunslick 1 229 Sep 4, 2017 08:51
Last Post: ythgilb
  Script-fu: How to create new, addressable layer using gimp-floating-sel-to-layer Bertholom√§us 2 230 Aug 31, 2017 14:32
Last Post: Bertholomäus

Forum Jump:


GIMP ForumPortalArchiveContactTermsRSS