todo.txt 9.4 KB
Newer Older
Jonathan Wilkes's avatar
Jonathan Wilkes committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Problems to put off until all (or most) sys_vgui calls are eliminated:
1) gui-side parser inside -- pdgui.js.  Currently we're splitting on newlines so we can separate
   gui_vmess from sys_vgui calls.  This makes it very difficult to handle multi-line msg and text
   boxes.
2) Semicolons -- currently the parser can't tell the difference between semicolons inside symbols
   and semicolons that end statements.  Again, this will be easy to solve once we eliminate sys_gui.

HTML5 which may not be standard yet:
1) mouse.pageX/pageY -- exist in Chromium but maybe not in FF et al.
2) svg 'overflow' attribute -- probably doesn't work in other browsers
3) document.body.scrollTop (might be Chromium-specific, not sure)
3) document.body.scrollLeft (might be Chromium-specific, not sure)

Node-webkit stuff:
1) popup API
2) new window API
3) window menus
4) (probably) present working directory
5) command line argv

user's avatar
user committed
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
Everything else: (A [*] means we've fixed it)
[ ] packaging as app, setting correct appname, etc
[ ] get -unique to work (relied on tcl [send] command)
[ ] check if patch windows with screenposition (0,0) get stuck underneath Ubuntu/OSX menu.  If so,
[ ] Node-webkit has a "screen" interface to retrieve the "workable" area of the screen
[*] choosing the same directory multiple times doesn't work (see dialog API page)
[ ] "Save As" on an overwrite doesn't seem to clear the dirty flag
[ ] figure out why there is a "pd_opendir" global var
[ ] pass k12 mode arg
[ ] implement recent files (using Pd's prefs loading mechanism instead of reimplementing gui prefs)
[ ] implement verifyquit
[ ] save and saveas dialogs aren't defaulting to the present working directory
[ ] implement automatic scrollbars and svg canvas resizing
[ ] add 'x' type to gui_vmess for saving canvas names, etc., as hex values
[x] destroy (or, more likely, hide) selection rectangle when not needed
[ ] change gui_text_select to gui_gobj_select
[ ] make it possible to have the inner cells of hradio change color with the selection,
    as the border currently does.  Tk just uses the non-hierarchical tags and appends the word
    "BASE".  (Maybe use an inner <g> to do this.)
[x] make mycnv use its own selection logic
[ ] abstract away appendChild
[ ] font-size should be set as css property for a class of text, rather than per each gobj in svg
[ ] remove the "fudge_factor" kludge in g_rtext.c, and handle fonts in a sane manner.  In doing so
    we must decide whether or not we want to be able to fetch the bounding box of objects from
    within a Pd patch.  (Currently [canvasinfo] and [objectinfo] are the only objects that can
    do this, though there might also be)
[x] replace things like gui_select_color with css
[ ] find a better approach to escaping characters for the gui than escape_double_quotes kludge
    (and handle any other problematic chars)
[ ] look into using <def> and <use> for scalars.
[ ] in draw_vis, make circle and ellipse radii attr floats instead of ints
[ ] should stroke-dasharray values be floats?
[ ] once garrays are drawn inside a <g> we won't have to individually erase each child of a scalar
[ ] clean up svg_sendupdate -- put a single gui_vmess at the end
[ ] svg_sendupdate -- make sure there aren't arbitrary %d's that should actually be %g's
[ ] svg_sendupdate -- need a gui interface for stuff like stroke-dasharray (and garrays)
[ ] ibid., for path data, points
[ ] make pdgui function names more consistent
[ ] in draw_vis, move tags to front of function call so they don't have to be in an array
[ ] in draw_vis, remove all the coords logic and let svg_togui do that work.  In svg_new,
    leverage the "d", "points", etc. methods to do the same.
[ ] remove the draw_vis warning/code about needing 2 points to draw
[ ] need to clean up dead windows inside patchwin object (on close)
[ ] make gui_menu_close filename less hacky (currently includes patch args in the middle) 
[ ] figure out why -nrt flag causes Pd to bail on the GUI (it wasn't doing this
    on the amd_64 virtual Jessie machine, nor on my 32-bit machine).
[ ] make dialogs with [yes/no] instead of [cancel/ok]
[ ] make a gui_mess interface for the edge cases that don't require args (similar to sys_gui)
[ ] make sure we're breaking down the socket properly from the GUI side on quit
[ ] looks like nwworkingdir isn't working for open/save dialogs atm
[ ] nwworkingdir only works on the second file open
[ ] implement the stuff at the end of saveas_callback (recentfiles et al)
[ ] make an "export" menu command for max patch saving.  That way we can accept a single extension
    for saving (.pd), and the native save dialog will warn us on potential file overwrites (even when
    the user neglects to type an extension).
[ ] draw graph inside gobj group
[ ] merge gui_text_select and gui_text_deselect
[ ] in function gui_cord_inspector_update, use parameter "moved" to flash text
[ ] cord_inspector_flash doesn't seem to be deterministic-- if you move among several cords very fast
    it will try to flash a non-existent svg item.  (Probably want to either make a permanent item in
    the pdcanvas.html for it, or hard-code a separate div.)
[ ] for data structure demos, change "" to 'none'
[ ] fix "Reselect" <ctrl-Enter> Keybinding.  It doesn't work atm because nw.js
    cannot bind to Enter.
[ ] keyup doesn't register autokeypresses, but keyname and key do
[ ] text_set doesn't work when a numbox is first created (but works otherwise)
[ ] clean up nw_create_window (doesn't need so many parameters)
[x] make a nice window API in C.  Window "foo-bar" type maps to "foo-bar.html"
[ ] implement the crappy iemgui color dialog presets
[x] find a simple translation API
[ ] use underscores for iemgui dialog element names
[ ] revisit the x_thick logic in g_slider.c.  It thickens the indicator when it's
    in the middle of the slider, but it's pretty obscure in the current impl.
[ ] for as many items as possible, hide them instead of removing from DOM
[ ] fix iemgui_font so it doesn't use tcl list syntax
[ ] change all the gui color char[MAXPDSTRING] junk to simple int, and do the conversion to
    hex html string in the gui
[ ] implement iemgui labels and its ascetic font chooser
[ ] think about scaling the svg instead of the page, and making the selection
    rectangle a div above that
[ ] change 'visible-width' to 'cnv-width'
[ ] in dialog_iemgui.html, use an object to store all the prop/value pairs that
    got sent.  That way we don't have to use all those awful tricks to
    conditionally fill the slots
[ ] look into the font metrics, see if we can use floating point fonts to simplify things
[ ] iemgui font configuration -- de-tcl-ize the {fontface fontsize} tcl list,
    then make it work
[x] do msg box click animation in css
[x] tgl 'X' doesn't show up
[ ] gui_graph_fill_border: use css class selectors instead of configuration
[ ] standardize javascript function names
[x] in gui_plot_vis, we have to check for gobj existence.  For some reason, at
    very fast drawing rates we end up with two svg elements if we don't check
    for this.  This would be simplified if gop stuff was just children of parent <group>
[x] add garray_update for changing the path coords without having to recreate
    the entire scalar edifice
[x] when duplicating a large number of iemguis, the label or border will eventually try to append
    to null.  It looks like it's receiving the correct gui calls from Pd, in the correct order.
    But for some reason the calls from Pd are getting split in the middle of a string.
    Not sure why, probably something to do with the hacky parser I wrote to split on newlines.
    Anyway, when we can just split on semis this problem should hopefully go away.  Make sure to
    test for it once that happens.
    Some gui_posts that show the problem-- the string is split between lines 2 and 3:
124
125
126
127
128
129
    nextCmd is gui_create_toggle ".x98be5e8","x99c0740","#000000",1,0,181,67,192,78,181,78,192,67,179,65;
    nextCmd is gui_iemgui_label_new ".x98be5e
    8","x99c0740",17,7,"#000000","","{{DejaVu Sans Mono} -10 normal}";
    nextCmd is gui_canvas_drawio ".x98be5e8","x99c0740",".x98be5e8.t99c0de0o0",179,79,186,80,179,65,"o",0,0,1;
    the tag for this XLET is .x98be5e8.t99c0de0o0

user's avatar
user committed
130
131
132
133
134
135
136
137
138
139
140
    Note: this was a simple problem of partial msgs not being prepended to the next buffer.

[ ] remove gui_text_select_color (css takes care of this)
[ ] add a canvas message to set a transform on the patchsvg.  Good for:
    * obscure display needs (zooming past the browser limits)
    * rotating for a display
    * transforming or scaling all scalars on a patch at once
    However: This will require more math on the mousemotion.  So this should probably wait until
    moving a lot of the editing code out of C and into the GUI
[ ] change 'array_element_fill' to 'element_fill', array_outline to 'array_element_outline' 
[ ] either nw_create_window should take fewer parameters or it should take an
141
    object with name: value pairs
user's avatar
user committed
142
[ ] getting the sense that glist_isselected should _always_ have
143
    glist_getcanvas(x) as its first parameter
user's avatar
user committed
144
[x] get rid of the old tcl specific sys_get_audio_apis
145
[ ] have a single function to set t_svg_attr
146
147
[ ] change x_x1..y2 to simple x_bbox[4], and change current x_bbox to
    x_cachebbox (or something like that)
user's avatar
user committed
148
[ ] figure out why gatom_retext sends a fill color to GUI
149
150
151
152
[ ] look into changing 'x' format specifier from \"x%.6lx\" to more generic
    \"%.6lx\". (Not exactly sure what good the "x" does there.)  It's only
    specified in s_inter and in editor_new, so it should be easy to amend
    if need be.
153

154
155
Crashers
--------