From: John Benediktsson Date: Sat, 16 May 2020 17:07:35 +0000 (-0700) Subject: ui.gadgets: formatting. X-Git-Tag: 0.99~3273 X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=b3412e89309d304433eb86c6c1d1a76ee21d6f66 ui.gadgets: formatting. --- diff --git a/basis/ui/gadgets/borders/borders.factor b/basis/ui/gadgets/borders/borders.factor index 10f3b71411..3418c89c0c 100644 --- a/basis/ui/gadgets/borders/borders.factor +++ b/basis/ui/gadgets/borders/borders.factor @@ -5,10 +5,10 @@ sequences ui.baseline-alignment ui.gadgets ; IN: ui.gadgets.borders TUPLE: border < aligned-gadget -{ size initial: { 0 0 } } -{ fill initial: { 0 0 } } -{ align initial: { 1/2 1/2 } } -{ min-dim initial: { 0 0 } } ; + { size initial: { 0 0 } } + { fill initial: { 0 0 } } + { align initial: { 1/2 1/2 } } + { min-dim initial: { 0 0 } } ; : new-border ( child class -- border ) new swap add-gadget ; inline diff --git a/basis/ui/gadgets/editors/editors.factor b/basis/ui/gadgets/editors/editors.factor index 143c9d6f2d..f123f07ee3 100644 --- a/basis/ui/gadgets/editors/editors.factor +++ b/basis/ui/gadgets/editors/editors.factor @@ -178,10 +178,10 @@ M: editor ungraft* editor [ caret-loc second ] [ caret-dim second ] bi + 2.0 - :> y editor editor-caret first :> row editor font>> foreground>> gl-color - editor preedit-underlines>> [ + editor preedit-underlines>> [ GL_LINE_BIT [ dup second glLineWidth - first editor preedit-start>> second dup 2array v+ first2 + first editor preedit-start>> second dup 2array v+ first2 [ row swap 2array editor loc>x 1.0 + y 2array ] [ row swap 2array editor loc>x 1.0 - y 2array ] bi* diff --git a/basis/ui/gadgets/line-support/line-support.factor b/basis/ui/gadgets/line-support/line-support.factor index b1cab467c1..da60a2023e 100644 --- a/basis/ui/gadgets/line-support/line-support.factor +++ b/basis/ui/gadgets/line-support/line-support.factor @@ -19,7 +19,8 @@ TUPLE: line-gadget < gadget GENERIC: line-leading* ( gadget -- n ) -M: line-gadget line-leading* font>> font-metrics leading>> ; +M: line-gadget line-leading* + font>> font-metrics leading>> ; GENERIC: line-leading ( gadget -- n ) @@ -32,7 +33,8 @@ M: line-gadget line-leading GENERIC: line-height* ( gadget -- n ) -M: line-gadget line-height* font>> font-metrics height>> ceiling ; +M: line-gadget line-height* + font>> font-metrics height>> ceiling >integer ; GENERIC: line-height ( gadget -- n ) diff --git a/basis/ui/gadgets/packs/packs.factor b/basis/ui/gadgets/packs/packs.factor index 9932554046..7a5fe428ed 100644 --- a/basis/ui/gadgets/packs/packs.factor +++ b/basis/ui/gadgets/packs/packs.factor @@ -6,7 +6,9 @@ ui.baseline-alignment.private ui.gadgets ; IN: ui.gadgets.packs TUPLE: pack < aligned-gadget -{ align initial: 0 } { fill initial: 0 } { gap initial: { 0 0 } } ; + { align initial: 0 } + { fill initial: 0 } + { gap initial: { 0 0 } } ;