Skip to content

Instantly share code, notes, and snippets.

@CarlTBarnes
Last active April 28, 2021 00:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save CarlTBarnes/c100da879ac9f5992b4dd7358132b8de to your computer and use it in GitHub Desktop.
Save CarlTBarnes/c100da879ac9f5992b4dd7358132b8de to your computer and use it in GitHub Desktop.
Find all LIST with DROP and make easier to see. Color light yellow like Tool Tip, add margin, grid lines lighter
!See https://clarionhub.com/t/how-to-make-drop-list-more-visible-on-the-window/3760?u=carlbarnes
!Make Drop lists more visible coloring like Tool Tip, easier to see with Format and +1 Line Spacing
!-------------------------
DropListPretty PROCEDURE
Fld LONG,AUTO
LstFEQ LONG,AUTO !Drop List is separate control Fld{PROP:Drop}
CODE
Fld=0
LOOP
Fld=0{PROP:NextField,Fld}
IF Fld=0 THEN BREAK.
CASE Fld{PROP:Type}
OF CREATE:List
OROF CREATE:Combo
LstFEQ = Fld{PROP:ListFEQ}
IF LstFEQ AND Fld{PROP:Drop}>0 THEN
LstFEQ{PROP:LineHeight}=1 + LstFEQ{PROP:LineHeight} ! +1 more line space easier to read
IF LstFEQ{PROP:Background}=COLOR:None THEN
LstFEQ{PROP:Background}=COLOR:InfoBackground !Yellow like tip
LstFEQ{PROP:FontColor} =COLOR:InfoText !font color like tip should be black
END
IF ~LstFEQ{PROP:FORMAT} THEN
LstFEQ{PROP:FORMAT}='999L(2)@s255@' !Margin of 2 else tight to line
END
!affects Entry not LIST --> LstFEQ{PROP:TextLeftMargin}=10
ELSE
LstFEQ=Fld !Normal LIST se set FEQ
END !If Drop List
LstFEQ{PROPLIST:Grid}=COLOR:ScrollBar !Color a Column Lines a bit Lighter than default dark gray
END !Case LIST or Combo
END !Loop Fields
RETURN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment