remove experimentation code (that I should have removed earlier)
This commit is contained in:
parent
ca99eb4a5e
commit
9f1b54c6fa
|
@ -731,41 +731,3 @@
|
|||
(send dc get-text-extent (if (null? (cdr strs)) "" (list-ref strs 1))))
|
||||
(max 0 (- (- label-h label-d)
|
||||
(- first-line-h first-line-d))))
|
||||
|
||||
(module+ main
|
||||
(begin
|
||||
(require racket/runtime-path)
|
||||
(define f2-docs-keybinding "f2 docs")
|
||||
(define k (new keymap%))
|
||||
(send k add-function f2-docs-keybinding
|
||||
(λ (txt evt)
|
||||
(send txt toggle-syncheck-docs)))
|
||||
(send k map-function "f2" f2-docs-keybinding)
|
||||
(define-runtime-path unit-docs.rktd "unit-docs.rktd")
|
||||
(define unit-docs
|
||||
(call-with-input-file unit-docs.rktd
|
||||
(λ (port)
|
||||
(let loop ()
|
||||
(define expr (read port))
|
||||
(if (eof-object? expr)
|
||||
'()
|
||||
(cons expr (loop)))))))
|
||||
(define f (if (eq? (system-type) 'macosx)
|
||||
(new frame% [width 600] [height 800] [label ""] [x 400])
|
||||
(new frame% [width 600] [height 750] [label ""])))
|
||||
(define t (new (docs-text-mixin scheme:text%)))
|
||||
(void (send t load-file (collection-file-path "unit.rkt" "drracket" "private")))
|
||||
(send t set-keymap k)
|
||||
(define ec (new (docs-editor-canvas-mixin editor-canvas%) [parent f] [editor t]))
|
||||
|
||||
(require racket/match)
|
||||
(time
|
||||
(begin
|
||||
(for ([line (in-list unit-docs)])
|
||||
(match-define `(,start ,end ,tag) line)
|
||||
(send t syncheck:add-docs-range start end tag (λ () (printf "visit docs url ~s\n" tag))))
|
||||
(printf "add-docs-range: ")))
|
||||
|
||||
(send f show #t))
|
||||
|
||||
#;(fetch-strs '(form ((lib "racket/private/class-internal.rkt") class))))
|
||||
|
|
Loading…
Reference in New Issue
Block a user