Re: Patch to save memory and speed up StyleTab

fuchur <[email protected]>
Newsgroups gmane.comp.window-managers.sawfish
Organization W.W
Message-ID <[email protected]>
Hi,

On Sun, 6 Apr 2014 20:51:41 +0200
wrote Christopher Roy Bratusek <[email protected]>:

>Am Sat, 5 Apr 2014 18:24:36 +0200
>schrieb fuchur <[email protected]>:
>
>> Hi,
>> 
>> Patch for StyleTab. Changes:
>> 
>> Mirrored the "top frame buttons" with the "bottom frame buttons" and
>> the "left frame buttons" with the "right frame buttons" in theme.jl.
>> (this save memory and speed up StyleTab)
>> 
>> Remove many images in Styltab. Please replace Default, Glass, Reduce,
>> Smoothly, and WixDa with folders from here:
>> https://sites.google.com/site/flohtransporter/files/StyleTab.tar.xz
>> 
>
>commited all your recent changes just now. Thanks for your continuing
>support. :)
>
>Regards,
>Chris

Patch for StyleTab. Changes:

Mirrored/copy/flip images in theme.jl. (Speed up StyleTab start)
Add style "Flat". It is a minimal style without "button animation" (for
slow CPUs).
Remove round corners in Glass, Reduce and WixDa.

Remove many images in Styltab. Please replace Default, Glass, Reduce,
Smoothly,Flat and WixDa with folders from here:
https://sites.google.com/site/flohtransporter/files/StyleTab.08.04.14.tar.xz


-- 
Regards,
Fuchur

GPG Fingerprint: CA3B 8204 5B3E 6D48 6D53  C116 E5BC 70D5 B8D7 B2B0
002.StyleTab.patch (text/x-patch, 55.8 KB)
diff -urNad sawfish/themes.orgi/StyleTab/theme.jl sawfish/themes/StyleTab/theme.jl
--- sawfish/themes.orgi/StyleTab/theme.jl
+++ sawfish/themes/StyleTab/theme.jl
@@ -52,12 +52,12 @@
 (defcustom styletab-c:styles 'Default "Frame and button style."
   :group (appearance StyleTab:group)
   :type symbol
-  :options (Default Reduce Glass WixDa Smoothly))
+  :options (Default Reduce Glass WixDa Smoothly Flat))
 
 (defcustom styletab-c:proposals 'Pink "Color proposals."
   :group (appearance StyleTab:group)
   :type symbol
-  :options (Default Reduce Glass WixDa Smoothly Brown Darkblue Blue Pink Green)
+  :options (Default Reduce Glass WixDa Smoothly Flat Brown Darkblue Blue Pink Green)
   :after-set (lambda () (color-changed)))
 
 (defcustom styletab-c:tabbar-marked t "Colorize tab/titelbar if it is to be added as a tab."
@@ -340,6 +340,7 @@
           ((Glass) (list "#5E5E70" '60 '40 '60))
           ((WixDa) (list "#6E6D8F" '20 '40 '60))
           ((Smoothly) (list "#75759E" '20 '40 '40))
+          ((Flat) (list "#6E6D8F" '20 '40 '60))
           ((Darkblue) (list "#00006E" '30 '70 '70))
           ((Brown) (list "#780000" '40 '40 '50))
           ((Blue) (list "#0000B4" '30 '40 '50))
@@ -353,7 +354,8 @@
           ((Reduce) (title-colors-reduce))
           ((Glass) (title-colors-glass))
           ((WixDa) (title-colors-wixda))
-          ((Smoothly) (title-colors-smoothly)))))
+          ((Smoothly) (title-colors-smoothly))
+          ((Flat) (title-colors-flat)))))
 
 (define title-colors-default
   (lambda ()
@@ -380,6 +382,11 @@
     `((focused . "#333333") (highlighted . "#000000") (clicked . "#000000") (inactive . "#666666") (inactive-highlighted . "#444444")
       (inactive-clicked . "#444444"))))
 
+(define title-colors-flat
+  (lambda ()
+    `((focused . "#F2F2F2") (highlighted . "#FFFFFF") (clicked . "#FFFFFF") (inactive . "#D9D9D9") (inactive-highlighted . "#E6E6E6")
+      (inactive-clicked . "#E6E6E6"))))
+
 (define button-width-custom
   (lambda ()
     (if (eq styletab-c:custom-button-width t)
@@ -389,7 +396,8 @@
             ((Reduce) (button-width-reduce))
             ((Glass) (button-width-glass))
             ((WixDa) (button-width-wixda))
-            ((Smoothly) (button-width-smoothly))))))
+            ((Smoothly) (button-width-smoothly))
+            ((Flat) (button-width-flat))))))
 
 (define button-width-add
   (lambda ()
@@ -400,7 +408,8 @@
             ((Reduce) (button-width-reduce))
             ((Glass) (button-width-glass))
             ((WixDa) (button-width-wixda))
-            ((Smoothly) (button-width-smoothly))))))
+            ((Smoothly) (button-width-smoothly))
+            ((Flat) (button-width-flat))))))
 
 (define button-width-set (lambda () (+ styletab-c:button-width (button-width-add))))
 (define button-width-zero (lambda () 0))
@@ -409,6 +418,7 @@
 (define button-width-glass (lambda () 0))
 (define button-width-wixda (lambda () -4))
 (define button-width-smoothly (lambda () 0))
+(define button-width-flat (lambda () 0))
 
 ;; end of tabtext
 (define tabbar-right-edge-width
@@ -418,7 +428,8 @@
           ((Reduce) 6)
           ((Glass) 3)
           ((WixDa) 3)
-          ((Smoothly) 3))))
+          ((Smoothly) 3)
+          ((Flat) 3))))
 
 ;; edge of first buttons left/right
 (define button-left-edge
@@ -428,7 +439,8 @@
           ((Reduce) 0)
           ((Glass) 0)
           ((WixDa) 0)
-          ((Smoothly) 0))))
+          ((Smoothly) 0)
+          ((Flat) 0))))
 
 (define button-right-edge
   (lambda ()
@@ -437,7 +449,8 @@
           ((Reduce) 1)
           ((Glass) 0)
           ((WixDa) 0)
-          ((Smoothly) 2))))
+          ((Smoothly) 2)
+          ((Flat) 0))))
 
 (define icon-edge
   (lambda ()
@@ -446,7 +459,8 @@
           ((Reduce) 2)
           ((Glass) 1)
           ((WixDa) 1)
-          ((Smoothly) 2))))
+          ((Smoothly) 2)
+          ((Flat) 1))))
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 
 ;;; frame-class, keys bindings
@@ -775,20 +789,28 @@
   (brighten-color color bright))
 
 (define (do-recolor img color)
-  (let ((recolorer
-         (make-image-recolorer color
-                               #:zero-channel blue-channel
-                               #:index-channel green-channel)))
-    (recolorer img)
-    img))
+  (if (and (eq styletab-c:styles 'Flat)
+           (not flat-buttons))
+      (make-sized-image 1 1 color)
+    (if (not (eq styletab-c:styles 'Flat))
+        (let ((recolorer
+               (make-image-recolorer color
+                                     #:zero-channel blue-channel
+                                     #:index-channel green-channel)))
+          (recolorer img)
+          img)
+      img)))
 
 (define (do-make-get-image img)
+  (if (and (eq styletab-c:styles 'Flat)
+           (not flat-buttons))
+      nil
     (or
      (table-ref styletab-c-frame-cache img)
      (let ((image
             (make-image img)))
        (table-set styletab-c-frame-cache img image)
-       image)))
+       image))))
 
 (define (base-tables-images w)
   (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-f.png"))
@@ -802,6 +824,142 @@
     (table-unset styletab-c-frame-cache w)
     (table-set styletab-c-frame-cache w `((focused . ,focus) (inactive . ,inact)))))
 
+(define (build-title-corner-images w)
+  (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-frame-top-left-" w "-f.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark 0 styletab-c:focus-frame-color)
+                             (get-recolor-dark 0 (get-color (nth 0 (proposals-colors)))))))
+        (inact (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-frame-top-left-" w "-i.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark (* styletab-c:inactive-dimout 20) styletab-c:unfocus-frame-color)
+                             (get-recolor-dark (nth 1 (proposals-colors)) (get-color (nth 0 (proposals-colors))))))))
+      (table-unset styletab-c-frame-cache (concat "top-frame-top-left-" w))
+      (table-set styletab-c-frame-cache (concat "top-frame-top-left-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache (concat "top-frame-top-right-" w))
+      (table-set styletab-c-frame-cache (concat "top-frame-top-right-" w)
+                 `((focused . ,(flip-image-horizontally (copy-image focus))) (inactive . ,(flip-image-horizontally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache (concat "left-frame-top-left-" w))
+      (table-set styletab-c-frame-cache (concat "left-frame-top-left-" w)
+                 `((focused . ,(flip-image-diagonally (copy-image focus))) (inactive . ,(flip-image-diagonally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache (concat "left-frame-bottom-left-" w))
+      (table-set styletab-c-frame-cache (concat "left-frame-bottom-left-" w)
+                 `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus)))) 
+                   (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact))))))
+      (table-unset styletab-c-frame-cache (concat "right-frame-top-right-" w))
+      (table-set styletab-c-frame-cache (concat "right-frame-top-right-" w)
+                 `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus)))) 
+                   (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact))))))
+      (table-unset styletab-c-frame-cache (concat "right-frame-bottom-right-" w))
+      (table-set styletab-c-frame-cache (concat "right-frame-bottom-right-" w)
+                 `((focused . ,(flip-image-vertically (flip-image-horizontally (flip-image-diagonally (copy-image focus))))) 
+                   (inactive . ,(flip-image-vertically (flip-image-horizontally (flip-image-diagonally (copy-image inact)))))))))
+
+(define (build-cursor-images w)
+  (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-frame-title-" w "-f.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark 0 styletab-c:focus-frame-color)
+                             (get-recolor-dark 0 (get-color (nth 0 (proposals-colors)))))))
+        (inact (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-frame-title-" w "-i.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark (* styletab-c:inactive-dimout 20) styletab-c:unfocus-frame-color)
+                             (get-recolor-dark (nth 1 (proposals-colors)) (get-color (nth 0 (proposals-colors))))))))
+      (table-unset styletab-c-frame-cache (concat "top-frame-title-" w))
+      (table-set styletab-c-frame-cache (concat "top-frame-title-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache (concat "left-frame-title-" w))
+      (table-set styletab-c-frame-cache (concat "left-frame-title-" w)
+                 `((focused . ,(flip-image-diagonally (copy-image focus))) (inactive . ,(flip-image-diagonally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache (concat "right-frame-title-" w))
+      (table-set styletab-c-frame-cache (concat "right-frame-title-" w)
+                 `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus)))) 
+                   (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact))))))))
+
+(define (build-title-images w)
+  (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-f.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark 0 styletab-c:focus-frame-color)
+                             (get-recolor-dark 0 (get-color (nth 0 (proposals-colors)))))))
+        (inact (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-i.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark (* styletab-c:inactive-dimout 20) styletab-c:unfocus-frame-color)
+                             (get-recolor-dark (nth 1 (proposals-colors)) (get-color (nth 0 (proposals-colors))))))))
+      (table-unset styletab-c-frame-cache (concat "top-" w))
+      (table-set styletab-c-frame-cache (concat "top-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache (concat "bottom-" w))
+      (table-set styletab-c-frame-cache (concat "bottom-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache (concat "left-" w))
+      (table-set styletab-c-frame-cache (concat "left-" w)
+                 `((focused . ,(flip-image-diagonally (copy-image focus))) (inactive . ,(flip-image-diagonally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache (concat "right-" w))
+      (table-set styletab-c-frame-cache (concat "right-" w)
+                 `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus)))) 
+                   (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact))))))))
+
+(define (build-border-images w)
+  (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-f.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark 0 styletab-c:focus-frame-color)
+                             (get-recolor-dark 0 (get-color (nth 0 (proposals-colors)))))))
+        (inact (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-i.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark (* styletab-c:inactive-dimout 20) styletab-c:unfocus-frame-color)
+                             (get-recolor-dark (nth 1 (proposals-colors)) (get-color (nth 0 (proposals-colors))))))))
+      (table-unset styletab-c-frame-cache (concat "top-" w))
+      (table-set styletab-c-frame-cache (concat "top-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache "right-frame-left-border")
+      (table-set styletab-c-frame-cache "right-frame-left-border" `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache '"top-frame-right-border")
+      (table-set styletab-c-frame-cache '"top-frame-right-border"
+                 `((focused . ,(flip-image-horizontally (copy-image focus))) (inactive . ,(flip-image-horizontally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"left-frame-right-border")
+      (table-set styletab-c-frame-cache '"left-frame-right-border"
+                 `((focused . ,(flip-image-horizontally (copy-image focus))) (inactive . ,(flip-image-horizontally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"top-frame-bottom-border")
+      (table-set styletab-c-frame-cache '"top-frame-bottom-border"
+                 `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus))))
+                   (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact))))))
+      (table-unset styletab-c-frame-cache '"right-frame-bottom-border")
+      (table-set styletab-c-frame-cache '"right-frame-bottom-border"
+                 `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus))))
+                   (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact))))))
+      (table-unset styletab-c-frame-cache '"left-frame-bottom-border")
+      (table-set styletab-c-frame-cache '"left-frame-bottom-border"
+                 `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus))))
+                   (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact))))))
+      (table-unset styletab-c-frame-cache '"right-frame-top-border")
+      (table-set styletab-c-frame-cache '"right-frame-top-border"
+                 `((focused . ,(flip-image-diagonally (copy-image focus)))
+                   (inactive . ,(flip-image-diagonally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"left-frame-top-border")
+      (table-set styletab-c-frame-cache '"left-frame-top-border"
+                 `((focused . ,(flip-image-diagonally (copy-image focus)))
+                   (inactive . ,(flip-image-diagonally (copy-image inact)))))))
+
+(define (build-corner-images w)
+  (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-f.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark 0 styletab-c:focus-frame-color)
+                             (get-recolor-dark 0 (get-color (nth 0 (proposals-colors)))))))
+        (inact (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" "top-" w "-i.png"))
+                           (if (eq styletab-c:custom-frame-colors t)
+                               (get-recolor-dark (* styletab-c:inactive-dimout 20) styletab-c:unfocus-frame-color)
+                             (get-recolor-dark (nth 1 (proposals-colors)) (get-color (nth 0 (proposals-colors))))))))
+      (table-unset styletab-c-frame-cache (concat "top-" w))
+      (table-set styletab-c-frame-cache (concat "top-" w) `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache "right-frame-bottom-left-corner")
+      (table-set styletab-c-frame-cache "right-frame-bottom-left-corner" `((focused . ,focus) (inactive . ,inact)))
+      (table-unset styletab-c-frame-cache '"top-frame-bottom-right-corner")
+      (table-set styletab-c-frame-cache '"top-frame-bottom-right-corner"
+                 `((focused . ,(flip-image-horizontally (copy-image focus))) (inactive . ,(flip-image-horizontally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"left-frame-bottom-right-corner")
+      (table-set styletab-c-frame-cache '"left-frame-bottom-right-corner"
+                 `((focused . ,(flip-image-horizontally (copy-image focus))) (inactive . ,(flip-image-horizontally (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"right-frame-top-left-corner")
+      (table-set styletab-c-frame-cache '"right-frame-top-left-corner"
+                 `((focused . ,(flip-image-vertically (copy-image focus))) (inactive . ,(flip-image-vertically (copy-image inact)))))
+      (table-unset styletab-c-frame-cache '"left-frame-top-right-corner")
+      (table-set styletab-c-frame-cache '"left-frame-top-right-corner"
+                 `((focused . ,(flip-image-diagonally (copy-image focus))) (inactive . ,(flip-image-diagonally (copy-image inact)))))))
+
 (define (tab-tables-images x w)
   (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" x "-" w "-f.png"))
                            (if (eq styletab-c:custom-frame-colors t)
@@ -869,36 +1027,97 @@
                                                                    (if (eq styletab-c:hightlight-tabbar t) 
                                                                        (/ (nth 2 (proposals-colors)) 2) 0)
                                                                    (get-recolor-bright 20 (get-color (nth 0 (proposals-colors))))))))))
-    (when (equal x '"top")
-      (table-unset styletab-c-frame-cache (concat x "-" w))
-      (table-set styletab-c-frame-cache (concat x "-" w) `((focused . ,focus) (highlighted . ,highl) (inactive . ,inact) 
-                                                           (inactive-highlighted . ,in-hi)))
-      (table-unset styletab-c-frame-cache (concat "bottom" "-" w))
-      (table-set styletab-c-frame-cache (concat "bottom" "-" w) `((focused . ,focus) (highlighted . ,highl) (inactive . ,inact) 
-                                                           (inactive-highlighted . ,in-hi)))
-      (table-unset styletab-c-frame-cache (concat x "-" w "-m"))
-      (table-set styletab-c-frame-cache (concat x "-" w "-m") `((focused . ,focus-m) (highlighted . ,highl-m) (inactive . ,inact-m) 
-                                                           (inactive-highlighted . ,in-hi-m)))
-      (table-unset styletab-c-frame-cache (concat "bottom" "-" w "-m"))
-      (table-set styletab-c-frame-cache (concat "bottom" "-" w "-m") `((focused . ,focus-m) (highlighted . ,highl-m) (inactive . ,inact-m) 
-                                                           (inactive-highlighted . ,in-hi-m))))
-    (when (equal x '"left")
-      (table-unset styletab-c-frame-cache (concat x "-" w))
-      (table-set styletab-c-frame-cache (concat x "-" w) `((focused . ,focus) (highlighted . ,highl) (inactive . ,inact) 
-                                                           (inactive-highlighted . ,in-hi)))
-      (table-unset styletab-c-frame-cache (concat "right" "-" w))
-      (table-set styletab-c-frame-cache (concat "right" "-" w) `((focused . ,(flip-image-horizontally (copy-image focus))) 
-                                                                 (highlighted . ,(flip-image-horizontally (copy-image highl)))
-                                                                 (inactive . ,(flip-image-horizontally (copy-image inact)))
-                                                                 (inactive-highlighted . ,(flip-image-horizontally (copy-image in-hi)))))
-      (table-unset styletab-c-frame-cache (concat x "-" w "-m"))
-      (table-set styletab-c-frame-cache (concat x "-" w "-m") `((focused . ,focus-m) (highlighted . ,highl-m) (inactive . ,inact-m) 
-                                                           (inactive-highlighted . ,in-hi-m)))
-      (table-unset styletab-c-frame-cache (concat "right" "-" w "-m"))
-      (table-set styletab-c-frame-cache (concat "right" "-" w "-m") `((focused . ,(flip-image-horizontally (copy-image focus-m))) 
-                                                                 (highlighted . ,(flip-image-horizontally (copy-image highl-m)))
-                                                                 (inactive . ,(flip-image-horizontally (copy-image inact-m)))
-                                                                 (inactive-highlighted . ,(flip-image-horizontally (copy-image in-hi-m))))))))
+    (table-unset styletab-c-frame-cache (concat x "-" w))
+    (table-set styletab-c-frame-cache (concat x "-" w) `((focused . ,focus) (highlighted . ,highl) (inactive . ,inact) 
+                                                         (inactive-highlighted . ,in-hi)))
+    (table-unset styletab-c-frame-cache (concat "bottom" "-" w))
+    (table-set styletab-c-frame-cache (concat "bottom" "-" w) `((focused . ,focus) (highlighted . ,highl) (inactive . ,inact) 
+                                                                (inactive-highlighted . ,in-hi)))
+    (table-unset styletab-c-frame-cache (concat x "-" w "-m"))
+    (table-set styletab-c-frame-cache (concat x "-" w "-m") `((focused . ,focus-m) (highlighted . ,highl-m) (inactive . ,inact-m) 
+                                                              (inactive-highlighted . ,in-hi-m)))
+    (table-unset styletab-c-frame-cache (concat "bottom" "-" w "-m"))
+    (table-set styletab-c-frame-cache (concat "bottom" "-" w "-m") `((focused . ,focus-m) (highlighted . ,highl-m) (inactive . ,inact-m) 
+                                                                     (inactive-highlighted . ,in-hi-m)))
+    (when (equal w '"frame-tab-left-icon")
+      (table-unset styletab-c-frame-cache "left-frame-tab-top")
+      (table-set styletab-c-frame-cache "left-frame-tab-top" `((focused . ,(flip-image-diagonally (copy-image focus))) 
+                                                               (highlighted . ,(flip-image-diagonally (copy-image highl)))
+                                                               (inactive . ,(flip-image-diagonally (copy-image inact)))
+                                                               (inactive-highlighted . ,(flip-image-diagonally (copy-image in-hi)))))
+      (table-unset styletab-c-frame-cache "left-frame-tab-top-m")
+      (table-set styletab-c-frame-cache "left-frame-tab-top-m" `((focused . ,(flip-image-diagonally (copy-image focus-m))) 
+                                                               (highlighted . ,(flip-image-diagonally (copy-image highl-m)))
+                                                               (inactive . ,(flip-image-diagonally (copy-image inact-m)))
+                                                               (inactive-highlighted . ,(flip-image-diagonally (copy-image in-hi-m)))))
+      (table-unset styletab-c-frame-cache "left-frame-tab-bottom-icon")
+      (table-set styletab-c-frame-cache 
+                 "left-frame-tab-bottom-icon" `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus)))) 
+                                                (highlighted . ,(flip-image-vertically (flip-image-diagonally (copy-image highl))))
+                                                (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact))))
+                                                (inactive-highlighted . ,(flip-image-vertically (flip-image-diagonally (copy-image in-hi))))))
+      (table-unset styletab-c-frame-cache "left-frame-tab-bottom-icon-m")
+      (table-set styletab-c-frame-cache 
+                 "left-frame-tab-bottom-icon-m" `((focused . ,(flip-image-vertically (flip-image-diagonally (copy-image focus-m)))) 
+                                                (highlighted . ,(flip-image-vertically (flip-image-diagonally (copy-image highl-m))))
+                                                (inactive . ,(flip-image-vertically (flip-image-diagonally (copy-image inact-m))))
+                                                (inactive-highlighted . ,(flip-image-vertically (flip-image-diagonally (copy-image in-hi-m))))))
+      (table-unset styletab-c-frame-cache "right-frame-tab-top")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab-top" `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus))))
+                                         (highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image highl))))
+                                         (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact))))
+                                         (inactive-highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image in-hi))))))
+      (table-unset styletab-c-frame-cache "right-frame-tab-top-m")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab-top-m" `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus-m))))
+                                         (highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image highl-m))))
+                                         (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact-m))))
+                                         (inactive-highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image in-hi-m))))))
+      (table-unset styletab-c-frame-cache "right-frame-tab-bottom-icon")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab-bottom-icon" `((focused . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                       (flip-image-diagonally (copy-image focus))))) 
+                                                 (highlighted . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                           (flip-image-diagonally (copy-image highl)))))
+                                                 (inactive . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                        (flip-image-diagonally (copy-image inact)))))
+                                                 (inactive-highlighted . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                                    (flip-image-diagonally (copy-image in-hi)))))))
+      (table-unset styletab-c-frame-cache "right-frame-tab-bottom-icon-m")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab-bottom-icon-m" `((focused . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                       (flip-image-diagonally (copy-image focus-m))))) 
+                                                 (highlighted . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                           (flip-image-diagonally (copy-image highl-m)))))
+                                                 (inactive . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                        (flip-image-diagonally (copy-image inact-m)))))
+                                                 (inactive-highlighted . ,(flip-image-horizontally (flip-image-vertically 
+                                                                                                    (flip-image-diagonally (copy-image in-hi-m))))))))
+    (when (equal w '"frame-tab")
+      (table-unset styletab-c-frame-cache "left-frame-tab")
+      (table-set styletab-c-frame-cache "left-frame-tab" `((focused . ,(flip-image-diagonally (copy-image focus))) 
+                                                           (highlighted . ,(flip-image-diagonally (copy-image highl)))
+                                                           (inactive . ,(flip-image-diagonally (copy-image inact)))
+                                                           (inactive-highlighted . ,(flip-image-diagonally (copy-image in-hi)))))
+      (table-unset styletab-c-frame-cache "left-frame-tab-m")
+      (table-set styletab-c-frame-cache "left-frame-tab-m" `((focused . ,(flip-image-diagonally (copy-image focus-m))) 
+                                                             (highlighted . ,(flip-image-diagonally (copy-image highl-m)))
+                                                             (inactive . ,(flip-image-diagonally (copy-image inact-m)))
+                                                             (inactive-highlighted . ,(flip-image-diagonally (copy-image in-hi-m)))))
+      (table-unset styletab-c-frame-cache "right-frame-tab")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab" `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus)))) 
+                                     (highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image highl))))
+                                     (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact))))
+                                     (inactive-highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image in-hi))))))
+      (table-unset styletab-c-frame-cache "right-frame-tab-m")
+      (table-set styletab-c-frame-cache 
+                 "right-frame-tab-m" `((focused . ,(flip-image-horizontally (flip-image-diagonally (copy-image focus-m)))) 
+                                       (highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image highl-m))))
+                                       (inactive . ,(flip-image-horizontally (flip-image-diagonally (copy-image inact-m))))
+                                       (inactive-highlighted . ,(flip-image-horizontally (flip-image-diagonally (copy-image in-hi-m)))))))))
+
 (define (base-button-tables-images w x)
   (let ((focus (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w x "-f.png"))
                            (if (eq styletab-c:custom-frame-colors t)
@@ -930,6 +1149,7 @@
                                                              (clicked . ,(flip-image-horizontally (copy-image click))) 
                                                              (inactive . ,(flip-image-horizontally (copy-image inact))) 
                                                              (inactive-clicked . ,(flip-image-horizontally (copy-image in-cl))))))))
+(define flat-buttons nil)
 (define scale-w nil)
 (define scale-h nil)
 (define (button-tables-images w x color always)
@@ -939,170 +1159,169 @@
              (setq scale-h (- styletab-c:title-dimension 4)))
     (progn (setq scale-w (- styletab-c:title-dimension 4))
            (setq scale-h (+ styletab-c:title-dimension (button-width-custom)))))
+  (if (eq styletab-c:styles 'Flat)
+      (setq flat-buttons t))
   (let ((focus (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-f.png"))
                                         (if (eq styletab-c:custom-frame-colors t)
                                             (get-recolor-dark 0 (if (and always color) color styletab-c:focus-frame-color))
                                           (get-recolor-dark 0 (if (and always color) color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
-        (highl (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-h.png"))
-                                        (if (eq styletab-c:custom-frame-colors t)
-                                            (get-recolor-bright (* styletab-c:active-hightlight-brighten 20)
-                                                                (if color color styletab-c:focus-frame-color))
-                                          (get-recolor-bright (nth 2 (proposals-colors))
-                                                              (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
-        (click (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-c.png"))
-                                        (if (eq styletab-c:custom-frame-colors t)
-                                            (get-recolor-bright (* styletab-c:active-hightlight-brighten 20)
-                                                                (if color color styletab-c:focus-frame-color))
-                                          (get-recolor-bright (nth 2 (proposals-colors))
-                                                              (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
-        (inact (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-i.png"))
-                                        (if (eq styletab-c:custom-frame-colors t)
-                                            (get-recolor-dark (* styletab-c:inactive-dimout 20)
-                                                              (if (and always color) color styletab-c:unfocus-frame-color))
-                                          (get-recolor-dark (nth 1 (proposals-colors))
-                                                            (if (and always color) color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
-        (in-hi (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-ih.png"))
-                                        (if (eq styletab-c:custom-frame-colors t)
-                                            (get-recolor-bright (- (* styletab-c:inactive-hightlight-brighten 20) (* styletab-c:inactive-dimout 20))
-                                                                (if color color styletab-c:unfocus-frame-color))
-                                          (get-recolor-bright (- (nth 3 (proposals-colors)) (nth 1 (proposals-colors)))
-                                                              (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
-        (in-cl (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-ic.png"))
-                                        (if (eq styletab-c:custom-frame-colors t)
-                                            (get-recolor-bright (- (* styletab-c:inactive-hightlight-brighten 20) (* styletab-c:inactive-dimout 20))
-                                                                (if color color styletab-c:unfocus-frame-color))
-                                          (get-recolor-bright (- (nth 3 (proposals-colors)) (nth 1 (proposals-colors)))
-                                                              (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h)))
-    (when (equal w '"top")
-      (table-unset styletab-c-frame-cache (concat "top" "-frame-" x "-button"))
-      (table-set styletab-c-frame-cache (concat "top" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click) 
-                                                                               (inactive . ,inact) (inactive-highlighted . ,in-hi) 
-                                                                               (inactive-clicked . ,in-cl))))
-    (when (equal w '"top")
-      (table-unset styletab-c-frame-cache (concat "bottom" "-frame-" x "-button"))
-      (table-set styletab-c-frame-cache (concat "bottom" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click)
+        highl click inact in-hi in-cl)
+    (when (not (eq styletab-c:styles 'Flat))
+      (setq highl (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-h.png"))
+                                           (if (eq styletab-c:custom-frame-colors t)
+                                               (get-recolor-bright (* styletab-c:active-hightlight-brighten 20)
+                                                                   (if color color styletab-c:focus-frame-color))
+                                             (get-recolor-bright (nth 2 (proposals-colors))
+                                                                 (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
+      (setq click (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-c.png"))
+                                           (if (eq styletab-c:custom-frame-colors t)
+                                               (get-recolor-bright (* styletab-c:active-hightlight-brighten 20)
+                                                                   (if color color styletab-c:focus-frame-color))
+                                             (get-recolor-bright (nth 2 (proposals-colors))
+                                                                 (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
+      (setq inact (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-i.png"))
+                                           (if (eq styletab-c:custom-frame-colors t)
+                                               (get-recolor-dark (* styletab-c:inactive-dimout 20)
+                                                                 (if (and always color) color styletab-c:unfocus-frame-color))
+                                             (get-recolor-dark (nth 1 (proposals-colors))
+                                                               (if (and always color) color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
+      (setq in-hi (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-ih.png"))
+                                           (if (eq styletab-c:custom-frame-colors t)
+                                               (get-recolor-bright (- (* styletab-c:inactive-hightlight-brighten 20) (* styletab-c:inactive-dimout 20))
+                                                                   (if color color styletab-c:unfocus-frame-color))
+                                             (get-recolor-bright (- (nth 3 (proposals-colors)) (nth 1 (proposals-colors)))
+                                                                 (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h))
+      (setq in-cl (scale-image (do-recolor (do-make-get-image (concat (symbol-name styletab-c:styles) "/" w "-frame-" x "-button-ic.png"))
+                                           (if (eq styletab-c:custom-frame-colors t)
+                                               (get-recolor-bright (- (* styletab-c:inactive-hightlight-brighten 20) (* styletab-c:inactive-dimout 20))
+                                                                   (if color color styletab-c:unfocus-frame-color))
+                                             (get-recolor-bright (- (nth 3 (proposals-colors)) (nth 1 (proposals-colors)))
+                                                                 (if color color (get-color (nth 0 (proposals-colors))))))) scale-w scale-h)))
+    (setq flat-buttons nil)
+    (if (eq styletab-c:styles 'Flat)
+        (mapcar (lambda (z) 
+                  (table-unset styletab-c-frame-cache (concat z "-frame-" x "-button"))
+                  (table-set styletab-c-frame-cache (concat z "-frame-" x "-button") `(,(copy-image focus)))) 
+                (list "top" "bottom" "left" "right"))
+      
+      (when (equal w '"top")
+        (table-unset styletab-c-frame-cache (concat "top" "-frame-" x "-button"))
+        (table-set styletab-c-frame-cache (concat "top" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click) 
+                                                                                 (inactive . ,inact) (inactive-highlighted . ,in-hi) 
+                                                                                 (inactive-clicked . ,in-cl))))
+      (when (equal w '"top")
+        (table-unset styletab-c-frame-cache (concat "bottom" "-frame-" x "-button"))
+        (table-set styletab-c-frame-cache (concat "bottom" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click)
+                                                                                    (inactive . ,inact) (inactive-highlighted . ,in-hi) 
+                                                                                    (inactive-clicked . ,in-cl))))
+      (when (equal w '"left")
+        (table-unset styletab-c-frame-cache (concat "left" "-frame-" x "-button"))
+        (table-set styletab-c-frame-cache (concat "left" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click) 
                                                                                   (inactive . ,inact) (inactive-highlighted . ,in-hi) 
                                                                                   (inactive-clicked . ,in-cl))))
-    (when (equal w '"left")
-      (table-unset styletab-c-frame-cache (concat "left" "-frame-" x "-button"))
-      (table-set styletab-c-frame-cache (concat "left" "-frame-" x "-button") `((focused . ,focus) (highlighted . ,highl) (clicked . ,click) 
-                                                                               (inactive . ,inact) (inactive-highlighted . ,in-hi) 
-                                                                               (inactive-clicked . ,in-cl))))
-    (when (equal w '"left")
-      (table-unset styletab-c-frame-cache (concat "right" "-frame-" x "-button"))
-      (table-set styletab-c-frame-cache (concat "right" "-frame-" x "-button") `((focused . ,(flip-image-horizontally (copy-image focus))) 
-                                                                                 (highlighted . ,(flip-image-horizontally (copy-image highl))) 
-                                                                                 (clicked . ,(flip-image-horizontally (copy-image click))) 
-                                                                                 (inactive . ,(flip-image-horizontally (copy-image inact))) 
-                                                                                 (inactive-highlighted . ,(flip-image-horizontally (copy-image in-hi))) 
-                                                                                 (inactive-clicked . ,(flip-image-horizontally (copy-image in-cl))))))))
+      (when (equal w '"left")
+        (table-unset styletab-c-frame-cache (concat "right" "-frame-" x "-button"))
+        (table-set styletab-c-frame-cache (concat "right" "-frame-" x "-button") `((focused . ,(flip-image-horizontally (copy-image focus))) 
+                                                                                   (highlighted . ,(flip-image-horizontally (copy-image highl))) 
+                                                                                   (clicked . ,(flip-image-horizontally (copy-image click))) 
+                                                                                   (inactive . ,(flip-image-horizontally (copy-image inact))) 
+                                                                                   (inactive-highlighted . ,(flip-image-horizontally (copy-image in-hi))) 
+                                                                                  (inactive-clicked . ,(flip-image-horizontally (copy-image in-cl)))))))))
 ;; frames/tabbar
 (define top-frame-icon-title-images
   (make-image (concat (symbol-name styletab-c:styles) "/" "top-frame-icon-title-images-f.png")))
-(define (tabbar-horizontal-images)
-  (mapcar (lambda (w) (mapcar (lambda (x)
-                               (tab-tables-images x w)) (list "top"))) (list "frame-tab-left-icon" "frame-tab" "frame-tab-right")))
-(define (tabbar-vertical-images)
-  (mapcar (lambda (w) (mapcar (lambda (x)
-                               (tab-tables-images x w)) (list "left"))) (list "frame-tab-top" "frame-tab" "frame-tab-bottom-icon")))
-(define (title-cursor-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-title-cursor"))) (list "top" "bottom" "left" "right")))
-(define (title-nocursor-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-title-nocursor"))) (list "top" "bottom" "left" "right")))
-(define (top-border-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-top-border"))) (list "bottom" "left" "right")))
-(define (top-left-corner-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-top-left-corner"))) (list "top" "bottom" "left" "right")))
-(define (top-right-corner-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-top-right-corner"))) (list "top" "bottom" "left" "right")))
-(define (top-left-corner-shaped-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-top-left-corner-shaped"))) (list "top" "left")))
-(define (top-right-corner-shaped-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-top-right-corner-shaped"))) (list "top" "right")))
-(define (title-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-title"))) (list "top" "bottom" "left" "right")))
-(define (left-border-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-left-border"))) (list "top" "bottom" "right")))
-(define (right-border-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-right-border"))) (list "top" "bottom" "left")))
-(define (bottom-left-corner-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-bottom-left-corner"))) (list "top" "bottom" "left" "right")))
-(define (bottom-border-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-bottom-border"))) (list "top" "left" "right")))
-(define (bottom-right-corner-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-bottom-right-corner"))) (list "top" "bottom" "left" "right")))
-(define (bottom-left-corner-shaped-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-bottom-left-corner-shaped"))) (list "bottom" "left")))
-(define (bottom-right-corner-shaped-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-bottom-right-corner-shaped"))) (list "bottom" "right")))
+(define (bottom-all-images)
+  (mapcar (lambda (w) (base-tables-images (concat "bottom" w))) (list "-frame-title-cursor" "-frame-title-nocursor" "-frame-top-border"
+                                                                      "-frame-top-left-corner" "-frame-top-right-corner" "-frame-left-border"
+                                                                      "-frame-right-border" "-frame-bottom-left-corner-shaped" 
+                                                                      "-frame-bottom-right-corner-shaped" "-frame-bottom-left-corner" 
+                                                                      "-frame-bottom-right-corner")))
+(define (base-title-corner-images)
+  (mapcar (lambda (w) (build-title-corner-images w)) (list "corner" "corner-shaped")))
+(define (base-cursor-images)
+  (mapcar (lambda (w) (build-cursor-images w)) (list "cursor" "nocursor")))
+(define (base-title-images)
+  (mapcar (lambda (w) (build-title-images w)) (list "frame-title")))
+(define (base-border-images)
+  (mapcar (lambda (w) (build-border-images w)) (list "frame-left-border")))
+(define (base-corner-images)
+  (mapcar (lambda (w) (build-corner-images w)) (list "frame-bottom-left-corner")))
 
 ;; buttons
 (define (base-button-images)
   (mapcar (lambda (w) (base-button-tables-images  w "-frame-button")) (list "top" "left")))
-(define (space-button-images)
-  (mapcar (lambda (w) (base-tables-images (concat w "-frame-title"))) (list "top" "bottom" "left" "right")))
 (define (close-button-images)
   (button-tables-images "top" "close" styletab-c:hightlight-close (if (eq styletab-c:hightlight-close-all t) t))
-  (button-tables-images "left" "close" styletab-c:hightlight-close (if (eq styletab-c:hightlight-close-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "close" styletab-c:hightlight-close (if (eq styletab-c:hightlight-close-all t) t))))
 (define (menu-button-images)
   (button-tables-images "top" "menu" styletab-c:hightlight-menu (if (eq styletab-c:hightlight-menu-all t) t))
-  (button-tables-images "left" "menu" styletab-c:hightlight-menu (if (eq styletab-c:hightlight-menu-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "menu" styletab-c:hightlight-menu (if (eq styletab-c:hightlight-menu-all t) t))))
 (define (iconify-button-images)
   (button-tables-images "top" "iconify" styletab-c:hightlight-iconify (if (eq styletab-c:hightlight-iconify-all t) t))
-  (button-tables-images "left" "iconify" styletab-c:hightlight-iconify (if (eq styletab-c:hightlight-iconify-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "iconify" styletab-c:hightlight-iconify (if (eq styletab-c:hightlight-iconify-all t) t))))
 (define (move-resize-button-images)
   (button-tables-images "top" "move-resize" styletab-c:hightlight-move-resize (if (eq styletab-c:hightlight-move-resize-all t) t))
-  (button-tables-images "left" "move-resize" styletab-c:hightlight-move-resize (if (eq styletab-c:hightlight-move-resize-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "move-resize" styletab-c:hightlight-move-resize (if (eq styletab-c:hightlight-move-resize-all t) t))))
 (define (rename-button-images)
   (button-tables-images "top" "rename" styletab-c:hightlight-rename (if (eq styletab-c:hightlight-rename-all t) t))
-  (button-tables-images "left" "rename" styletab-c:hightlight-rename (if (eq styletab-c:hightlight-rename-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "rename" styletab-c:hightlight-rename (if (eq styletab-c:hightlight-rename-all t) t))))
 (define (frame-type-button-images)
   (button-tables-images "top" "frame-type" styletab-c:hightlight-frame-type (if (eq styletab-c:hightlight-frame-type-all t) t))
-  (button-tables-images "left" "frame-type" styletab-c:hightlight-frame-type (if (eq styletab-c:hightlight-frame-type-all t) t)))
+  (unless (eq styletab-c:styles 'Flat)
+       (button-tables-images "left" "frame-type" styletab-c:hightlight-frame-type (if (eq styletab-c:hightlight-frame-type-all t) t))))
 (define (maximize-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-maximize
                                             (if (eq styletab-c:hightlight-maximize-all t) t))) (list "maximize" "unmaximize"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-maximize
-                                            (if (eq styletab-c:hightlight-maximize-all t) t))) (list "maximize" "unmaximize")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-maximize
+                                                 (if (eq styletab-c:hightlight-maximize-all t) t))) (list "maximize" "unmaximize"))))
 (define (shade-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-shade
                                             (if (eq styletab-c:hightlight-shade-all t) t))) (list "shade" "unshade"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-shade
-                                            (if (eq styletab-c:hightlight-shade-all t) t))) (list "shade" "unshade")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-shade
+                                                 (if (eq styletab-c:hightlight-shade-all t) t))) (list "shade" "unshade"))))
 (define (sticky-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-sticky
                                             (if (eq styletab-c:hightlight-sticky-all t) t))) (list "sticky" "unsticky"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-sticky
-                                            (if (eq styletab-c:hightlight-sticky-all t) t))) (list "sticky" "unsticky")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-sticky
+                                                 (if (eq styletab-c:hightlight-sticky-all t) t))) (list "sticky" "unsticky"))))
 (define (lock-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-lock
                                             (if (eq styletab-c:hightlight-lock-all t) t))) (list "lock" "unlock"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-lock
-                                            (if (eq styletab-c:hightlight-lock-all t) t))) (list "lock" "unlock")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-lock
+                                                 (if (eq styletab-c:hightlight-lock-all t) t))) (list "lock" "unlock"))))
 (define (prev-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-prev
                                             (if (eq styletab-c:hightlight-prev-all t) t))) (list "prev" "prev-last"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-prev
-                                            (if (eq styletab-c:hightlight-prev-all t) t))) (list "prev" "prev-last")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-prev
+                                                 (if (eq styletab-c:hightlight-prev-all t) t))) (list "prev" "prev-last"))))
 (define (next-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-next
                                             (if (eq styletab-c:hightlight-next-all t) t))) (list "next" "next-last"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-next
-                                            (if (eq styletab-c:hightlight-next-all t) t))) (list "next" "next-last")))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-next
+                                                 (if (eq styletab-c:hightlight-next-all t) t))) (list "next" "next-last"))))
 (define (raise-lower-button-images)
   (mapcar (lambda (w) (button-tables-images "top" w styletab-c:hightlight-raise-lower
                                             (if (eq styletab-c:hightlight-raise-lower-all t) t))) (list "raise-lower" "ontop" "unontop"))
-  (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-raise-lower
-                                            (if (eq styletab-c:hightlight-raise-lower-all t) t))) (list "raise-lower" "ontop" "unontop")))
-
-(define (recolor-base)
-  (title-cursor-images) (title-nocursor-images) (top-border-images) (top-left-corner-images) (top-right-corner-images) (top-left-corner-shaped-images)
-  (top-right-corner-shaped-images) (title-images) (left-border-images) (right-border-images) (bottom-left-corner-images) (bottom-border-images)
-  (bottom-right-corner-images) (bottom-left-corner-shaped-images) (bottom-right-corner-shaped-images) (base-button-images) (space-button-images))
+  (unless (eq styletab-c:styles 'Flat)
+       (mapcar (lambda (w) (button-tables-images "left" w styletab-c:hightlight-raise-lower
+                                                 (if (eq styletab-c:hightlight-raise-lower-all t) t))) (list "raise-lower" "ontop" "unontop"))))
 
+(define (recolor-base) (base-title-corner-images) (base-cursor-images) (base-title-images) (base-button-images) (base-border-images) (base-corner-images)
+        (bottom-all-images))
 (define (recolor-tab)
-  (tabbar-horizontal-images) (tabbar-vertical-images))
-
+  (mapcar (lambda (w) (mapcar (lambda (x)
+                                (tab-tables-images x w)) (list "top"))) (list "frame-tab-left-icon" "frame-tab" "frame-tab-right")))
 (define (recolor-close-button)
   (close-button-images))
 (define (recolor-menu-button)
signature.asc (application/pgp-signature, 198 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)

iEYEARECAAYFAlNEKzgACgkQ5bxw1bjXsrDKGwCgnQqBNAzgWxDBxmfvJMZT3i52
WEIAn3ZJ8Wv0YoGp2PQ/doEK7GpPMmys
=FOO9
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.