Revision: 2470 http://vexi.svn.sourceforge.net/vexi/?rev=2470&view=rev Author: clrg Date: 2007-10-15 06:10:17 -0700 (Mon, 15 Oct 2007)
Log Message: ----------- Make tabs more size agnostic and use settings Modified Paths: -------------- trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/settings.t trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tab.t trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tabpane.t Modified: trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/settings.t =================================================================== --- trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/settings.t 2007-10-15 13:02:00 UTC (rev 2469) +++ trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/settings.t 2007-10-15 13:10:17 UTC (rev 2470) @@ -8,6 +8,10 @@ <ui:box /> static.surfacefill = "#d4d0c8"; + static.tabfill = "#d4d0c8"; + static.tabfill_unselected = "#c4c0b8"; + static.textcolor = "black"; + static.textcolor_disabled = "#888888"; static.themeauthor = "Charles Goodwin"; static.themename = "Win2k"; static.themepath = "org.vexi.theme.win2k"; Modified: trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tab.t =================================================================== --- trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tab.t 2007-10-15 13:02:00 UTC (rev 2469) +++ trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tab.t 2007-10-15 13:10:17 UTC (rev 2470) @@ -9,20 +9,37 @@ </meta:doc> <lib:tab /> - <ui:box redirect=":$content" align="center" layout="layer" shrink="true"> - <bevel id="bg" align="topleft" form="tabtop"> - <lay:pad padding="3"> - <focusborder id="focus"> - <lay:pad padding="2 6"> - <ui:box id="content" /> - </lay:pad> - </focusborder> - </lay:pad> - </bevel> + <ui:box redirect=":$content" align="center" layout="layer" minheight="29" shrink="true"> + <ui:box id="bg" orient="vertical"> + <ui:box height="3" vshrink="true" /> + <ui:box layout="layer"> + thisbox.fill ++= function(v) { + thisbox[0].fill = v; + thisbox[1][0].fill = v; + return; + } + <bevel align="topleft" form="tabtop" /> + <ui:box align="bottomleft" x="1" height="2"> + <ui:box /> + <ui:box width="2" shrink="true" /> + </ui:box> + </ui:box> + <ui:box height="2" vshrink="true" /> + </ui:box> + <lay:pad id="pad" orient="vertical" padding="3"> + <ui:box height="3" vshrink="true" /> + <focusborder id="focus"> + <lay:pad padding="2 6"> + <ui:box id="content" /> + </lay:pad> + </focusborder> + <ui:box height="2" vshrink="true" /> + </lay:pad> thisbox.th_bg = $bg; thisbox.th_content = $content; thisbox.th_focus = $focus; + thisbox.th_pad = $pad; // assign static traps thisbox.enabled ++= static.enabledFunc; @@ -39,23 +56,28 @@ /** 'raise' when selected */ static.selectedFunc = function(v) { cascade = v; - var t = trapee; - var b = t.th_bg; - if (t.selected) { - b.fill = "#d4d0c8"; - b[0].padding = 3; - b.y = 0; + var b = trapee.th_bg; + var p = trapee.th_pad; + if (trapee.selected) { + b[0].display = false; + b[1].fill = .settings..tabfill; + b[2].display = false; + p[0].display = false; + p[2].height = 5; } else { - b.fill = "#c4c0b8"; - b[0].padding = "1 3"; - b.y = 2; + b[0].display = true; + b[1].fill = .settings..tabfill_unselected; + b[2].display = true; + p[0].display = true; + p[2].height = 2; } } /** adjust textcolor depending on enabled state */ static.enabledFunc = function(v) { cascade = v; - trapee.th_content.textcolor = trapee.enabled ? "black" : "#888888"; + trapee.th_content.textcolor = + trapee.enabled ? .settings..textcolor : .settings..textcolor_disabled; } </vexi> Modified: trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tabpane.t =================================================================== --- trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tabpane.t 2007-10-15 13:02:00 UTC (rev 2469) +++ trunk/widgets/org.vexi.widgets/src/org/vexi/theme/win2k/tabpane.t 2007-10-15 13:10:17 UTC (rev 2470) @@ -17,7 +17,7 @@ </button> <ui:box width="3" /> </ui:box> - <ui:box id="headwrap" layout="place"> + <ui:box id="headwrap" layout="layer"> <ui:box id="head" align="topleft" hshrink="true" /> </ui:box> <ui:box id="rightwrap" shrink="true" display="false"> @@ -80,5 +80,10 @@ $headwrap.width ++= syncHeadFunc; $headwrap.x ++= syncHeadFunc; + $wrap.height ++= function(v) { + $content.y = v-2; + cascade = v; + } + </ui:box> </vexi> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Vexi-svn mailing list Vexi-svn@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/vexi-svn