friends, I have been going crazy with what I hope is just an easily debuggable problem that somehow is eluding me. I have a new colorscheme as its own package:
#lang info
(define deps '("base"))
(define framework:color-schemes
'(#hash((colors
.
((framework:basic-canvas-background #(255 255 232))
(framework:default-text-color #(0 0 0))
(framework:disabled-background-color #(190 190 190))
(framework:failed-search-background-color #(255 192 203))
(framework:line-numbers #(0 0 0))
(framework:line-numbers-current-line-number-background #(34 139 34))
(framework:line-numbers-current-line-number-foreground #(255 255 255))
(framework:line-numbers-when-word-wrapping #(169 169 169))
(framework:misspelled-text-color #(0 0 0))
(framework:paren-match-color #(233 233 233))
(framework:program-contour-current-location-bar #(173 216 230))
(framework:warning-background-color #(255 255 0))
(framework:syntax-color:scheme:comment #(64 128 128) )
(framework:syntax-color:scheme:constant #(66 66 66) )
(framework:syntax-color:scheme:error #(255 0 0) )
(framework:syntax-color:scheme:hash-colon-keyword #(128 0 255) )
(framework:syntax-color:scheme:keyword #(38 38 128) bold )
(framework:syntax-color:scheme:other #(0 0 0) )
(framework:syntax-color:scheme:parenthesis #(128 128 255) )
(framework:syntax-color:scheme:string #(66 66 66) )
(framework:syntax-color:scheme:symbol #(38 38 128) normal italic )
(framework:syntax-color:scheme:text #(41 128 38) )
))
(name . "Color Test 2")
(white-on-black-base? . #f))))
Somehow, DrRacket doesn’t see it after it is installed. Installing other colorschemes work. This one doesn’t. There is no error installing the package but it never appears in the colors preference options in DrRacket. Can someone spot anything wrong with it?
@acorso522 has joined the channel
@andre Looks fine to me. Restarting DrRacket didn’t help?
@soegaard2 restarting DrRacket didn’t help. Doing raco setup
didn’t work either. I restarted dozen times during the last couple days. If I install colorschemes from the catalog, it works. If I try to install this one from a folder, it doesn’t. There is no error and the package appear installed on raco pkg show
, but the colorscheme doesn’t appear in DrRacket, no matter how many times I restart.
@james275 has joined the channel
@andre: my initial observation is that it works fine if you remove normal
, italic
, bold
from your color scheme.
OK, the problem is actually with normal
. It doesn’t seem to be a valid value.
@soegaard2 that is quite odd because it is a valid value for a style delta. Well, it is solved then, thanks a ton for your help. I was really lost on it. I didn’t really know how to debug this.
@wanpeebaw I see you are doing some bioinformatics. I wrote a racket library for bioinformatics which is.currently on hold due to other priorities. Would be interested to hear from you what your needs are for bioinformatics in racket
@andre I think @sorawee gets the credit for this one :slightly_smiling_face:
@andre FWIW, you can run DrRacket in command-line as follows:
PLTSTDERR="debug@color-scheme" drracket
This will show you error messages regarding color scheme. For example, with your colorscheme, I see
color-scheme: expected something matching:
'(listof (and/c hash? immutable? valid-key-values?))
for framework:color-schemes in /Users/sorawee/git/racket-repos/test-color-scheme, got
'(#hash((colors
.
((framework:basic-canvas-background #(255 255 232))
(framework:default-text-color #(0 0 0))
(framework:disabled-background-color #(190 190 190))
(framework:failed-search-background-color #(255 192 203))
(framework:line-numbers #(0 0 0))
(framework:line-numbers-current-line-number-background #(34 139 34))
(framework:line-numbers-current-line-number-foreground
#(255 255 255))
(framework:line-numbers-when-word-wrapping #(169 169 169))
(framework:misspelled-text-color #(0 0 0))
(framework:paren-match-color #(233 233 233))
(framework:program-contour-current-location-bar #(173 216 230))
(framework:warning-background-color #(255 255 0))
(framework:syntax-color:scheme:comment #(64 128 128))
(framework:syntax-color:scheme:constant #(66 66 66))
(framework:syntax-color:scheme:error #(255 0 0))
(framework:syntax-color:scheme:hash-colon-keyword #(128 0 255))
(framework:syntax-color:scheme:keyword #(38 38 128) bold)
(framework:syntax-color:scheme:other #(0 0 0))
(framework:syntax-color:scheme:parenthesis #(128 128 255))
(framework:syntax-color:scheme:string #(66 66 66))
(framework:syntax-color:scheme:symbol #(38 38 128) normal)
(framework:syntax-color:scheme:text #(41 128 38))))
(name . "Color Test 2")
(white-on-black-base? . #f)))
It’s not that very helpful because valid-key-values?
is hidden pretty deep in the GUI library, but at least you would know that there’s something wrong with your configuration
thanks a lot @sorawee I’m fixing the scripts to generate the colorschemes here. :smile: