Minor UI improvements
parent
7026c53769
commit
d2d0404af3
|
|
@ -1,5 +1,4 @@
|
|||
- UI word wrap problem
|
||||
- UI focus problem after restoring
|
||||
|
||||
- unix i/o: problems with passing f to syscalls
|
||||
- if a primitive throws an error, :c doesn't show the call frame there
|
||||
|
|
@ -51,10 +50,15 @@
|
|||
+ help:
|
||||
|
||||
- automatically update help graph when adding/removing articles/words
|
||||
- help search:
|
||||
- edit distance algorithm
|
||||
- store positions in index
|
||||
- phrase scoring algorithm based on how close the terms occur?
|
||||
|
||||
+ ui:
|
||||
|
||||
- initial track size is still wrong
|
||||
- word wrap in UI broken again
|
||||
- table line styles
|
||||
- x11 input methods
|
||||
- roundoff is still not quite right with tracks
|
||||
- new browser:
|
||||
|
|
@ -73,7 +77,7 @@
|
|||
- use display lists
|
||||
- reimplement tab completion
|
||||
- cocoa:
|
||||
- horizontal scrolling
|
||||
- horizontal wheel scrolling
|
||||
- polish OS X menu bar code
|
||||
- dock menu
|
||||
- variable width word wrap
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
USING: help inspector parser prettyprint ;
|
||||
USING: generic hashtables help inspector namespaces parser
|
||||
prettyprint sequences words ;
|
||||
|
||||
ARTICLE: "handbook" "Factor documentation"
|
||||
{ $subsection "changes" }
|
||||
|
|
@ -28,4 +29,21 @@ ARTICLE: "handbook" "Factor documentation"
|
|||
{ $subsection "streams" }
|
||||
{ $subsection "parser" }
|
||||
{ $subsection "prettyprint" }
|
||||
{ $subsection "alien" } ;
|
||||
{ $subsection "alien" }
|
||||
{ $heading "Index" }
|
||||
{ $subsection "article-index" }
|
||||
{ $subsection "primitive-index" }
|
||||
{ $subsection "type-index" }
|
||||
{ $subsection "class-index" } ;
|
||||
|
||||
ARTICLE: "article-index" "Article index"
|
||||
{ $outliner [ articles get hash-keys ] } ;
|
||||
|
||||
ARTICLE: "primitive-index" "Primitive index"
|
||||
{ $outliner [ all-words [ primitive? ] subset ] } ;
|
||||
|
||||
ARTICLE: "type-index" "Type index"
|
||||
{ $outliner [ builtins get [ ] subset ] } ;
|
||||
|
||||
ARTICLE: "class-index" "Class index"
|
||||
{ $outliner [ classes get [ ] subset ] } ;
|
||||
|
|
|
|||
|
|
@ -53,11 +53,5 @@ SYMBOL: help-graph
|
|||
: xref-articles ( -- )
|
||||
all-articles [ links-out ] help-graph get build-graph ;
|
||||
|
||||
: help-outliner ( seq quot -- | quot: obj -- )
|
||||
swap sort-articles [ ($subsection) terpri ] each-with ;
|
||||
|
||||
: articles. ( -- )
|
||||
articles get hash-keys [ help ] help-outliner ;
|
||||
|
||||
: links-in. ( article -- )
|
||||
links-in [ links-in. ] help-outliner ;
|
||||
|
|
|
|||
|
|
@ -204,3 +204,9 @@ M: link summary
|
|||
: $io-error
|
||||
drop
|
||||
"Throws an error if the I/O operation fails." $errors ;
|
||||
|
||||
: help-outliner ( seq quot -- | quot: obj -- )
|
||||
swap sort-articles [ ($subsection) terpri ] each-with ;
|
||||
|
||||
: $outliner ( content -- )
|
||||
first call natural-sort [ help ] help-outliner ;
|
||||
|
|
|
|||
|
|
@ -115,7 +115,6 @@ DEFER: described-menu
|
|||
{ }
|
||||
{ "Run..." menu-run-file "o" }
|
||||
{ }
|
||||
{ "Apropos" apropos-window "r" }
|
||||
{ "Globals" globals-window "" }
|
||||
{ "Memory" memory-window "" }
|
||||
{ }
|
||||
|
|
@ -145,10 +144,5 @@ DEFER: described-menu
|
|||
{ {
|
||||
"Help"
|
||||
{ "Factor Documentation" handbook-window "?" }
|
||||
{ }
|
||||
{ "Help Index" articles-window "" }
|
||||
{ "Types" types-window "" }
|
||||
{ "Classes" classes-window "" }
|
||||
{ "Primitives" primitives-window "" }
|
||||
} }
|
||||
} described-menu set-main-menu ;
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
! Copyright (C) 2005, 2006 Slava Pestov.
|
||||
! See http://factorcode.org/license.txt for BSD license.
|
||||
IN: gadgets-scrolling
|
||||
USING: arrays gadgets gadgets-frames gadgets-viewports generic
|
||||
kernel math namespaces sequences ;
|
||||
USING: arrays gadgets gadgets-frames gadgets-theme
|
||||
gadgets-viewports generic kernel math namespaces sequences ;
|
||||
|
||||
! A scroller combines a viewport with two x and y sliders.
|
||||
! The follows slot is set by scroll-to.
|
||||
|
|
@ -39,7 +39,8 @@ C: scroller ( gadget -- scroller )
|
|||
{ [ <x-slider> ] set-scroller-x @bottom }
|
||||
{ [ <y-slider> ] set-scroller-y @right }
|
||||
} make-frame*
|
||||
t over set-gadget-root? ;
|
||||
t over set-gadget-root?
|
||||
dup faint-boundary ;
|
||||
|
||||
: set-slider ( value page max slider -- )
|
||||
#! page/max/value are 3-vectors.
|
||||
|
|
|
|||
|
|
@ -21,38 +21,15 @@ prettyprint sequences words ;
|
|||
: memory-window ( -- )
|
||||
[ heap-stats. terpri room. ] "Memory" pane-window ;
|
||||
|
||||
: articles-window ( -- )
|
||||
[ articles. ] "Help index" pane-window ;
|
||||
|
||||
: types-window ( -- )
|
||||
[ builtins get [ ] subset [ help ] word-outliner ]
|
||||
"Types" pane-window ;
|
||||
|
||||
: classes-window ( -- )
|
||||
[ classes [ help ] word-outliner ]
|
||||
"Classes" pane-window ;
|
||||
|
||||
: primitives-window ( -- )
|
||||
[ all-words [ primitive? ] subset [ help ] word-outliner ]
|
||||
"Primitives" pane-window ;
|
||||
|
||||
: apropos-window ( -- )
|
||||
[ apropos ] <search-gadget> open-window ;
|
||||
|
||||
: globals-window ( -- )
|
||||
global show ;
|
||||
|
||||
: default-launchpad
|
||||
{
|
||||
{ "Listener" [ listener-window ] }
|
||||
{ "Browser" [ browser-window ] }
|
||||
{ "Documentation" [ handbook-window ] }
|
||||
{ "Help index" [ articles-window ] }
|
||||
{ "Browser" [ f browser-window ] }
|
||||
{ "Apropos" [ apropos-window ] }
|
||||
{ "Globals" [ globals-window ] }
|
||||
{ "Types" [ types-window ] }
|
||||
{ "Classes" [ classes-window ] }
|
||||
{ "Primitives" [ primitives-window ] }
|
||||
{ "Memory" [ memory-window ] }
|
||||
{ "Save image" [ save ] }
|
||||
{ "Exit" [ 0 exit ] }
|
||||
|
|
|
|||
|
|
@ -25,10 +25,8 @@ M: search-gadget gadget-gestures
|
|||
|
||||
C: search-gadget ( quot -- )
|
||||
[ set-search-gadget-quot ] keep {
|
||||
{ [ <pane> <scroller> dup faint-boundary ] set-search-gadget-scroller @center }
|
||||
{ [ <pane> <scroller> ] set-search-gadget-scroller @center }
|
||||
{ [ "" <editor> ] set-search-gadget-input @top }
|
||||
} make-frame* ;
|
||||
|
||||
M: search-gadget pref-dim* drop { 350 200 0 } ;
|
||||
|
||||
M: search-gadget focusable-child* search-gadget-input ;
|
||||
|
|
|
|||
Loading…
Reference in New Issue