Ignore:
Timestamp:
May 9, 2013 11:29:37 AM (11 years ago)
Author:
mmc
Message:

Fixes for nanoHUB ticket #258058 and #258045 -- note within a group tab
doesn't fill out the area properly. Should work better now. Also fixed
tabs to contain the window, instead of floating above the cotents as they
have for a long time.

Fixed boolean controls to have a more obvious on/off switch instead of a
checkbox. Fixed integers and spinners to use larger +/- buttons that are
easier to press on an iPad. Fixed numbers and other gauges to have the
same relief style as entries and other widgets.

Added new layout styles to groups: horizontal, vertical, tabs, and sentence.
You can now explicitly make a layout vertical instead of tabs by setting
the layout to "vertical" instead of throwing in a separator. Updated the
zoo/groups example to show off new horizontal and sentence types.

Fixed the "drawing" example in the zoo to gray out the trapezoid top when
it is disabled.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gui/scripts/spinint.tcl

    r3454 r3642  
    1818option add *Spinint.width 5 widgetDefault
    1919option add *Spinint.textBackground white widgetDefault
    20 
    21 blt::bitmap define Spinint-up {
    22 #define up_width 8
    23 #define up_height 4
    24 static unsigned char up_bits[] = {
    25    0x10, 0x38, 0x7c, 0xfe};
    26 }
    27 
    28 blt::bitmap define Spinint-down {
    29 #define arrow_width 8
    30 #define arrow_height 4
    31 static unsigned char arrow_bits[] = {
    32    0xfe, 0x7c, 0x38, 0x10};
    33 }
    3420
    3521itcl::class Rappture::Spinint {
     
    8268
    8369    itk_component add up {
    84         button $itk_component(controls).spinup -bitmap Spinint-up \
     70        button $itk_component(controls).spinup \
     71            -image [Rappture::icon intplus] \
    8572            -borderwidth 1 -relief raised -highlightthickness 0 \
    8673            -command [itcl::code $this bump up]
     
    8875        usual
    8976        ignore -borderwidth -highlightthickness
     77        rename -background -buttonbackground buttonBackground Background
    9078    }
    91     pack $itk_component(up) -side top -expand yes -fill both
     79    pack $itk_component(up) -side left -expand yes -fill both
    9280
    9381    itk_component add down {
    94         button $itk_component(controls).spindn -bitmap Spinint-down \
     82        button $itk_component(controls).spindn \
     83            -image [Rappture::icon intminus] \
    9584            -borderwidth 1 -relief raised -highlightthickness 0 \
    9685            -command [itcl::code $this bump down]
     
    9887        usual
    9988        ignore -borderwidth -highlightthickness
     89        rename -background -buttonbackground buttonBackground Background
    10090    }
    101     pack $itk_component(down) -side bottom -expand yes -fill both
     91    pack $itk_component(down) -side right -expand yes -fill both
    10292
    10393    eval itk_initialize $args
Note: See TracChangeset for help on using the changeset viewer.