HTML colours question

Started by cormullion, October 28, 2007, 04:18:04 AM

Previous topic - Next topic

cormullion

Here's a stripped-down version of something I'm working on. I want the text in the bottom pane to be white on black, but it's blue on black. Is there an easy fix?


(load  
  (string (env "NEWLISPDIR") "/guiserver.lsp")
  )

(set 'html-header [text]
<style>
body {
background-color: #000;
color: #fff;
}
</style>
[/text]
)

(gs:init)
(gs:frame 'Style 200 200 400 250 "Style")
(gs:panel 'MainPanel)
(gs:set-grid-layout 'MainPanel 3 1)

(gs:text-area 'string-input 'textfield-handler  1)
(gs:text-pane 'plain-output 'gs:no-action 1)
(gs:text-pane 'html-output  'gs:no-action "text/html")
(gs:set-editable 'html-output nil)

(gs:add-to 'MainPanel 'string-input 'plain-output 'html-output)
(gs:add-to 'Style 'MainPanel)

(gs:set-visible 'Style true)

(define (textfield-handler id text)
(gs:get-text id 'gettextcallback-handler))

(define (gettextcallback-handler id text)
  (and
    text
     (= id "MAIN:string-input")
     (set 'strng (base64-dec text))
     (set 'result (string {<p>} strng {</p>}))
     (gs:set-text 'plain-output result)
     (gs:set-text 'html-output (string html-header result))))

(gs:listen)

Lutz

#1
specify colors using 6 digits (3 pairs of digits rrggbb)



<style>
body {
   background-color: #000000;
   color: #FFFFFF;
}
</style>


Lutz

cormullion

#2
Thanks again Lutz! I'm glad you never sleep... :-)

Lutz

#3
QuoteThanks again Lutz! I'm glad you never sleep... :-)


at the moment I am on Los Angeles time, so its morning for me ;-)



Lutz