Page 6 of 15 FirstFirst ... 45678 ... LastLast
Results 51 to 60 of 143

Thread: A Beginner "How To" for gtkrc themes.

  1. #51
    Join Date
    Jan 2006
    Beans
    1,352

    Re: A Beginner "How To" for gtkrc themes.

    Post a picture of the GtkNotebook widget when you finish, I would like to see how you changed it's look.

  2. #52
    Join Date
    Apr 2007
    Location
    127.0.0.1
    Beans
    25
    Distro
    Xubuntu 7.04 Feisty Fawn

    Re: A Beginner "How To" for gtkrc themes.

    Presenting: the LadyLockheart theme made by me :)



    The panel:



    The tab curvature bit didn't have as big effect as I was hoping it would, but there's still a subtle change there. I also want to make a matching cursor and icon set before the theme as a whole is released to the world at large, though. This has turned into a bigger project than I initially thought! Of course, I have to figure out how to make icons and cursors before I can go further :x Looks like I've got another night of googling and inspecting other cursors and icons ahead of me.

    Oh, and here's the gtkrc file (but this time it's cleaned up a bit more; I took out the 'testing' bit for one thing :p):

    Code:
    # "Lady Lockheart" theme for Xfce, made by Ceil
    # Based on a Final Fantasy VII desktop, made by the
    # same author: http://www.deviantart.com/deviation/23611017/
    
    # Colours (shades of white, blue, and flesh)
    #
    # FFFFFF F3E6DD
    # F1EBF9 EAD8CB
    # D4D4F8 D6BEAC
    # C5BBED CAA990
    # B7A1F4 BE9373
    # 8080FF A77149
    # 5050FF 92572B
    # 0000FF 82481D
    
    style "default"
    {
    
      GtkRange::slider_width		= 14
      GtkRange::stepper_size		= 14
      GtkRange::stepper_spacing		= 2
      GtkRange::trough_border		= 0
      GtkScrollbar::min_slider_length	= 20
      GtkMenu::horizontal-padding		= 4
      GtkMenuItem::selected_shadow_type	= out
      GtkMenuItem::horizontal_padding	= 1
      GtkRadioButton::indicator_size	= 10
      GtkToolbar::shadow_type		= none
      GtkToolbar::button-relief		= normal
      GtkWidget::focus-line-width		= 0
      GtkNotebook::tab-curvature		= 3
      GtkNotebook::tab-overlap		= 3
    
      xthickness = 2
      ythickness = 2
    
      bg[NORMAL]		= "#FFFFFF"	# The normal colour.
      bg[PRELIGHT]		= "#F1EBF9"	# "On hover".
      bg[ACTIVE]		= "#C5BBED"	# When a button is pressed.
      bg[INSENSITIVE]	= "#D6BEAC"	# Disabled widget.
      bg[SELECTED]		= "#8080FF"	# When text is selected.
      fg[NORMAL]		= "#82481D"
      fg[PRELIGHT]		= "#BA9E89"
      fg[ACTIVE]		= "#A77149"
      fg[INSENSITIVE]	= "#5D4F44"
      fg[SELECTED]		= "#FFFFFF"
      text[NORMAL]		= "#92572B"
      text[PRELIGHT]	= "#82481D"
      text[ACTIVE]		= "#EAD8CB"
      text[INSENSITIVE]	= "#D6BEAC"
      text[SELECTED]	= "#FFFFFF"
      base[NORMAL]		= "#F1EBF9"
      base[PRELIGHT]	= "#F3E6DD"
      base[ACTIVE]		= "#D2B7A2"
      base[INSENSITIVE]	= "#8080FF"
      base[SELECTED]	= "#A88E77"
    
    }
    
    style "pbar" = "default"
    {
    
      xthickness = 0
      ythickness = 0
    
      bg[NORMAL]	= "#FFFFFF"
      bg[PRELIGHT]	= "#F1EBF9"
      engine "xfce" 
      {
         smooth_edge = true
         boxfill
         {
             fill_style = gradient
             orientation = auto
             shade_start = 1.13
             shade_end = 0.87
         }
      }
    
    }
    
    style "scale" = "default"
    {
    
      xthickness = 2
      ythickness = 2
    
      bg[NORMAL]		= "#D4D4F8"
      bg[PRELIGHT]		= "#F1EBF9"
      bg[ACTIVE]		= "#F1EBF9"
      bg[INSENSITIVE]	= "#B7A1F4"
      base[SELECTED]	= "#F1EBF9"
      base[ACTIVE]		= "#FFFFFF"
    
      engine "xfce"
      {
        grip_style = slide
        smooth_edge = true
        boxfill
        {
          fill_style = gradient
          shade_start = 1.13
          shade_end = 1.00
        }
      }
    
    }
    
    style "menubar" = "default"
    {
    
      xthickness = 0
      ythickness = 0
    
      engine "xfce"
      {
        boxfill
        {
          fill_style = gradient
          orientation = vertical
          shade_start = 0.92
          shade_end = 1.00
        }
      }
    }
    
    style "menuitem" = "default"
    {
    
      xthickness = 2
      ythickness = 2
    
      fg[NORMAL]		= "#8080FF"
      fg[PRELIGHT]		= "#0000FF"
    
      engine "xfce"
      {
        smooth_edge = true
        boxfill
        {
          fill_style = gradient
          orientation = auto
          shade_start = 1.13
          shade_end = 0.87
        }
      }
    }
    
    style "button" = "default"
    {
    
      xthickness = 2
      ythickness = 2
    
      fg[NORMAL]		= "#A77149"
      fg[PRELIGHT]		= "#82481D"
      fg[ACTIVE]		= "#92572B"
      fg[INSENSITIVE]	= "#5D4F44"
    
      engine "xfce"
      {
        boxfill
        {
          fill_style = gradient
          orientation = vertical
          shade_start = 1.13
          shade_end = 0.87
        }
      }
    }
    
    style "check" = "default"
    {
    
      xthickness = 1
      ythickness = 1
    
      bg[SELECTED]		= "#CAA990"
      base[NORMAL]		= "#F1EBF9"
      base[PRELIGHT]	= "#F3E6DD"
      base[ACTIVE]		= "#D2B7A2"
      base[INSENSITIVE]	= "#8080FF"
      base[SELECTED]	= "#A88E77"
    
    }
    
    style "frame" = "default"
    {
    
      xthickness	= 1
      ythickness	= 1
    
      fg[NORMAL]		= "#A77149"
      bg[NORMAL]		= "#D6BEAC"
    
    }
    
    style "tabs" = "default"
    {
    
      xthickness	= 1
      ythickness	= 1
    
      bg[ACTIVE]		= "#F1EBF9"
    
      engine "xfce"
      {
        boxfill
        {
          fill_style = gradient
          orientation = auto
          shade_start = 1.13
          shade_end = 1.00
        }
      }
    
    }
    
    widget_class "*"		style "default"
    
    widget_class "*Button*"		style "button"
    class "*Button*"		style "button"
    widget_class "*button*"		style "button"
    class "*button*"		style "button"
    widget_class "*OptionMenu*"	style "button"
    class "*OptionMenu*"		style "button"
    widget_class "*Tree*"		style "button"
    class "*Tree*"			style "button"
    
    widget_class "*CheckButton*"	style "check"
    class "*CheckButton*"		style "check"
    widget_class "*RadioButton*"	style "check"
    class "*RadioButton*"		style "check"
    widget_class "*ComboBox*"	style "check"
    class "*ComboBox*"		style "check"
    widget_class "*List*"		style "check"
    class "*List*"			style "check"
    widget_class "*Text*"		style "check"
    class "*Text*"			style "check"
    widget_class "*Entry*"		style "check"
    class "*Entry*"			style "check"
    widget_class "*ComboBoxEntry*"	style "check"
    class "*ComboBoxEntry*"		style "check"
    
    widget_class "*MenuBar"		style "menubar"
    class "*MenuBar"		style "menubar"
    widget_class "*ToolBar"		style "menubar"
    class "*ToolBar"		style "menubar"
    widget_class "*BonoboDockItem"	style "menubar"
    class "*BonoboDockItem"		style "menubar"
    widget_class "*HandleBox"	style "menubar"
    class "*HandleBox"		style "menubar"
    
    widget_class "*MenuItem*"	style "menuitem"
    class "*MenuItem*"		style "menuitem"
    
    widget_class "*GtkProgress*"	style "pbar"
    class "*GtkProgress*"		style "pbar"
    
    widget_class "*Scrollbar*"	style "scale"
    class "*Scrollbar*"		style "scale"
    widget_class "*GtkScale*"	style "scale"
    class "*GtkScale*"		style "scale"
    widget_class "*Scale*"		style "scale"
    class "*Scale*"			style "scale"
    widget_class "*Scroll*"		style "scale"
    class "*Scroll*"		style "scale"
    
    widget_class "*Frame*"		style "frame"
    class "*Frame*"			style "frame"
    
    widget_class "*Notebook*"	style "tabs"
    class "*Notebook*"		style "tabs"
    
    widget "xfwm"			style "default"
    class "MetaFrames"		style "default"
    widget_class "MetaFrames"	style "default"
    If someone can tell me how to change the background colour of the clock, that'd be great ;x That's the only big issue I've got left with the theme. But, I've got cursors to make :)

    Edit: Did some poking around in the Xfce theme engine source code, and it does indeed look like it's as limited as it seems. Here's the "tokens" (copied from xfce_rc_style.h), and all the options I think are possible with this particular engine:

    Code:
    enum
    {
        TOKEN_SMOOTHEDGE = G_TOKEN_LAST + 1,
        TOKEN_BOXFILL,
        TOKEN_FILL_STYLE,
        TOKEN_GRIP_STYLE,
        TOKEN_GRIP_NONE,
        TOKEN_GRIP_ROUGH,
        TOKEN_GRIP_SLIDE,
        TOKEN_GRADIENT,
        TOKEN_PLAIN,
        TOKEN_ORIENTATION,
        TOKEN_AUTO,
        TOKEN_HORIZONTAL,
        TOKEN_VERTICAL,
        TOKEN_NORTHERN_DIAGONAL,
        TOKEN_SOUTHERN_DIAGONAL,
        TOKEN_SHADE_START,
        TOKEN_SHADE_END,
        TOKEN_TRUE,
        TOKEN_FALSE
    };
    
    ^=- that's from the style header file. Here's all you can do with /engine "xfce"/ -=v
    
    engine "xfce" {
      smooth_edge = true, false
      grip_style = none, rough, slide
      boxfill {
        fill_style = gradient, plain
        orientation = auto, horizontal, vertical, northern_diagonal, southern_diagonal
        shade_start = FLOAT
        shade_end = FLOAT
      }
    }
    I was kind of hoping there'd be more :xThen, Xfce is meant to be light; but this theme engine is crazy light. Still, my pretty theme is pure Xfce :)

    Maybe one day I'll do the same for other theme engines. I've got a document with all the options for the Smooth engine I've seen used, but I haven't actually seen the source code for it. I'm not even sure I want to see the source for Clearlooks and Pixmap :x That much C code would probably give me a headache! Still, I hope this helps someone.
    Last edited by ceil420; July 3rd, 2007 at 05:49 PM.
    "Following our will and wind, we may just go where no one's been! We'll ride the spiral to the end and may just go where no one's been! Spiral out! Keep going!"

    -Maynard James Keenan

  3. #53
    Join Date
    Dec 2006
    Beans
    390
    Distro
    Ubuntu Development Release

    Re: A Beginner "How To" for gtkrc themes.

    Guide looks good, though I have yet to trial it.
    registered linux user 426057

  4. #54
    Join Date
    Jan 2006
    Beans
    1,352

    Re: A Beginner "How To" for gtkrc themes.

    Thank you, feel free to add any tips that you might know about xfce or any other theme engine.

    Also, any tips/links about custom icons, userChrome.css, panel images, and window decorations such as Emerald are also welcome....

  5. #55
    Join Date
    Apr 2007
    Location
    127.0.0.1
    Beans
    25
    Distro
    Xubuntu 7.04 Feisty Fawn

    Re: A Beginner "How To" for gtkrc themes.

    Only thing I know about custom icons is that you'll have your work cut out for you if you're planning on making a whole set; there's literally hundreds of them (737 svg icons alone in the gnome set; there are also six different sizes in png format). I don't know anything about anything else yet :x Here's my notes on the "smooth" engine, sorted alphabetically, but with no comments; it just shows every option I came across in /usr/share/themes:

    Code:
    engine "smooth" {
    
      real_sliders = true,false
      resize_grip = true,false
      tab_style = square,round
    
      arrow {
        etched = true,false
        insensitive {
          etched = true,false
        }
        solid = true,false
        style = CleanIce,wonderland
        xpadding = INT
        ypadding = INT
      }
    
      button {
        embeddable = true,false
      }
    
      check {
        fill { }
        line { }
        motif = false,true
        style = clean,wonderland
      }
    
      edge {
        line { }
      }
    
      fill {
        color1[STATUS] = "#HEX"
        color2[STATUS] = "#HEX"
        hdirection = vertical,fdiagonal
        quadratic = true,false
        shade1 = 0.00-1.99
        shade2 = 0.00-1.99
        style = shaded,solid,gradient
        vdirection = horizontal,fdiagonal
      }
    
      grip {
        count = INT
        fill { }
        spacing = INT
        style = mac_buds_in,none,dots_out,ns_buds_in
        tollbar_overlap = true,false
      }
    
      line {
        style = smooth,none,thin.flat
        thickness = INT
      }
    
      option {
        fill { }
        line { }
        motif = false,true
        style = round,circle,clean
      }
    
      progress {
        line { }
      }
    
      tabs {
        style = square
      }
    
      trough {
        fill { }
        line { }
        show_value = true,false
        xpadding = INT
        ypadding = INT
      }
    
    }
    And for something slightly off topic (but partly relevant, because I made them to go with my theme), I present my FFVII cursor theme :) I didn't make all 77 cursors; just the ones that actually get used. You can compare my chart with the one found at http://www.xed.ch/lwm/tcltkref/tk.cursor.html

    Last edited by ceil420; July 4th, 2007 at 02:52 AM. Reason: Disabling those annoying smileys -_-
    "Following our will and wind, we may just go where no one's been! We'll ride the spiral to the end and may just go where no one's been! Spiral out! Keep going!"

    -Maynard James Keenan

  6. #56
    Join Date
    Oct 2004
    Beans
    956
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: A Beginner "How To" for gtkrc themes.

    is there nothing in the source for the arrows? I find it hard to believe there's no arrow config. In the smooth engine you can do a little with size with
    Code:
    		arrow
    		{
    			style = cleanice
    			solid = TRUE
    			xpadding = 0
    			ypadding = 0
    
    			INSENSITIVE
    			{
    				etched = TRUE
    			}
    		}
    but don't even try
    Code:
    		arrow
    		{
    			xpadding = 0
    			ypadding = 0
    		}
    because you'll lock your puter

    In gnome the clock font can be controlled with
    Code:
    style "panel-clock"
    {
    fg[NORMAL] = "#FF0000"
    }
    widget "*.clock-applet-button.*" style "panel-clock"
    #widget "*PanelWidget*" style "panel-clock"
    #widget "*PanelApplet*" style "panel-clock"
    #widget_class "*Panel*GtkButton" style "panel-clock"
    but to get the bg to change I had to use
    Code:
    style "panel-clock"
    {
    bg[NORMAL] = "#FFFFFF"
    }
    widget "*.clock-applet-button.*" style "panel-clock"
    #widget "*PanelWidget*" style "panel-clock"
    widget "*PanelApplet*" style "panel-clock"
    #widget_class "*Panel*GtkButton" style "panel-clock"
    but then the panel buttons change to. Something to tinker with for ya. I haven't figured out the right combination in gnome.

    I am curious though. If you want to customize, why not use the smooth engine? It can look so much like the xfce engine. I know you don't get a few distinctions but if you want control the smooth engine has far more than any other engine.

    For the pager in gnome-panel
    style "pager" {

    }
    widget "*WnckPager" style "pager"
    of course put your bg and base colors in there.


    If you're like me and can't stand the panel handle in gnome use a 10x10 pixel transparent image and
    Code:
    style "handle"
    {
    engine "pixmap"
      {
        image
        {
          function			= HANDLE
          file              		= "pixel.png"
          border            		= { 0, 0, 0, 0 }
          stretch           		= TRUE
          orientation			= VERTICAL
        }
        image
        {
          function			= HANDLE
          file              		= "pixel.png"
          border            		= { 0, 0, 0, 0 }
          stretch           		= TRUE
          orientation			= HORIZONTAL
        }
      }
    }
    class "PanelAppletFrame" style "handle"
    class "GtkPaned"       	style "handle"
    class "*Panel*" style "handle"
    there was a time the smooth engine claimed to use images and I tried it, but it was horrible. Later versions it didn't work and I admit it would be useless since you can use multiple engines for a theme. I put the above handle code in my gtkrc-2.0 in my home dir
    Last edited by bvc; July 4th, 2007 at 07:44 AM.

  7. #57
    Join Date
    Jan 2006
    Beans
    1,352

    Re: A Beginner "How To" for gtkrc themes.

    Quote Originally Posted by ceil420 View Post

    ...from your picture in the above post...


    #3: Same question/issue as #2. I'd like the drop-down arrow thing to be the same shape/style as the one below it ("GtkCombo"), but don't know which class/widget to fit the style to.


    I found an answer for question #3.



    I fixed this default setting (that I noticed you don't have on your gtkrc):



    Code:
    GtkButton::focus-padding          = 0
    maybe try that...


    This is my new theme's look:




    this is a bit of code from my last theme that I fixed when making my new theme:





    Code:
    GtkButton::default_border         = {0, 0, 0, 0}
    GtkButton::default_outside_border = {0, 0, 0, 0}
    GtkButton::default_spacing        = 0
    GtkButton::focus-line-width       = 0
    GtkButton::focus-padding          = 0
    Last edited by crimesaucer; July 7th, 2007 at 10:38 PM.

  8. #58
    Join Date
    Oct 2004
    Beans
    956
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: A Beginner "How To" for gtkrc themes.

    Quote Originally Posted by crimesaucer View Post
    I found an answer for question #3.

    I fixed this default setting (that I noticed you don't have on your gtkrc):

    Code:
    GtkButton::focus-padding          = 0
    maybe try that...
    apply the button code of the button to the check style which includes
    widget_class "*Entry*"
    class "*Entry*"
    widget_class "*ComboBox*"
    class "*ComboBox*"

    Code:
      xthickness = 1
      ythickness = 1
    
      engine "xfce"
      {
        boxfill
        {
          fill_style = gradient
          orientation = vertical
          shade_start = 1.10
          shade_end = 0.95
        }
      }
    Of course removing those classes from the check style may resolve it as well.....I didn't try...

  9. #59
    Join Date
    Jan 2006
    Beans
    1,352

    Re: A Beginner "How To" for gtkrc themes.

    I had mine in style "default"

    and style "colored" = "default"


    ...just like most of the xubuntu default themes.

  10. #60
    Join Date
    Oct 2004
    Beans
    956
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: A Beginner "How To" for gtkrc themes.

    that doesn't tell me anything. All I know is when I did the above the buttons and arrows of the combobox's and buttons matched. Changing the focus-padding won't change the button.

Page 6 of 15 FirstFirst ... 45678 ... LastLast

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •