From e37c89a4346d2c2d7954880b55fcbb3037df4f83 Mon Sep 17 00:00:00 2001 From: Slava Pestov <slava@slava-pestovs-macbook-pro.local> Date: Tue, 17 Feb 2009 08:24:55 -0600 Subject: [PATCH] Tweak tables a bit --- basis/ui/gadgets/tables/tables.factor | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/basis/ui/gadgets/tables/tables.factor b/basis/ui/gadgets/tables/tables.factor index ee605185ec..c8c4d7c762 100644 --- a/basis/ui/gadgets/tables/tables.factor +++ b/basis/ui/gadgets/tables/tables.factor @@ -34,14 +34,15 @@ TUPLE: table < line-gadget { action initial: [ drop ] } single-click? { hook initial: [ ] } -{ gap initial: 6 } +{ gap initial: 2 } column-widths total-width focus-border-color { mouse-color initial: COLOR: black } -{ column-line-color initial: COLOR: dark-gray } +{ column-line-color initial: T{ rgba f 0 0 0 0 } } selection-required? selected-index selected-value mouse-index +{ takes-focus? initial: t } focused? ; : <table> ( rows renderer -- table ) @@ -263,7 +264,7 @@ M: table model-changed [ hand-rel second ] keep y>line ; : table-button-down ( table -- ) - dup request-focus + dup takes-focus?>> [ dup request-focus ] when dup control-value empty? [ drop ] [ dup [ mouse-row ] keep validate-line [ >>mouse-index ] [ (select-row) ] bi