jafl / jx_application_framework

JX is a full-featured C++ application framework and widget library (SDK) for use with the X Window System.

This URL has Read+Write access

100644 432 lines (355 sloc) 14.672 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
create new NPS email addresses to avoid spam
 
free upgrade
david-m@orbotech.com
 
jcc
* all windows disabled after click "Load" in Edit Macros dialog
 
medic:
accept connection or switch to gdb: should stop listening on port
need simple example to submit to ACE list
restart either xdebug or java: unable to listen on port & crashes on exit
also need to fix SetProgram()
 
2D plots
* printing to EPS -- unable to set file
 
option for polar grid: draw partial circles (only if both axes linear)
 
write CMVarTreeHelp#Plot2D
extract help from glove into generic section in libj2dplot
 
gdb
* don't allow run program until GDBDisplaySourceForMain has finished
 
Test suite
start, choose program, set bkpt, run
start, run, open file, stop, set bkpt, continue
start with program name, set bkpt, run
start with core name
switch from core dump to running binary
switch from running binary to core dump
switch from one program to another
 
upgrade dashboard widgets to YUI 3
 
-----
 
WindowManager
OSX
visible/visible +
visible/hidden/show +
hidden/visible moves down
hidden/hidden/show moves down
 
Metacity
window is not child of WM frame
 
jcc:
* git diff
http://yuilibrary.com/gitfaq/
http://www.eecs.harvard.edu/~cduan/technical/git/
 
medic:
breakpoint/watchpoint window (create/edit/delete)
 
gdb
enable call to UnlockDisplays(), when JXGetAssertHandler is defined
check every time symbols are loaded
 
xdebug
click stack trace: selection jumps back to last frame
temp breakpoint doesn't disappear
 
Enable XDSocket::StartTimer() when not debugging
Always update stack, even if Stack Trace window is hidden
Eliminate double call to get local vars
Preserve existing items; don't just delete all before update
request source from debugger instead of assuming that file:// exists
*set* values
support conditional breakpoints, etc.
 
java
after kill jvm, fails to run again
source-jar unzips to /tmp
display stderr from zip in cmd line window
delete /tmp directories when delete link or open different program
thread list
convert to tree
listen for thread start/death to update tree
start JVM
JVMDisplaySourceForMain
get Methods for main-class, find "main", get LineTable, get first line number, scroll to that
set breakpoint
request id for class (cache it)
listen for class unload events to clean up cache
request all methods for class (cache it)
search code index <-> line index for location
 
http://java.sun.com/javase/6/docs/technotes/guides/jpda/conninv.html
http://java.sun.com/javase/6/docs/technotes/guides/jpda/jdwp-spec.html
http://java.sun.com/javase/6/docs/platform/jpda/jdwp/jdwp-protocol.html
 
http://java.sun.com/j2se/1.5.0/docs/tooldocs/solaris/jdb.html
http://java.sun.com/javase/6/docs/technotes/guides/jpda/conninv.html
 
arrow
.sig input field in Accounts should be monospace
fix SaveState() so it doesn't need JFileArray
specify timeout for lockfile and handle it as lock failure
* doesn't save drafts if no inbox open
* doesn't recv mail if flush inbox during download (locking problem?)
* doesn't display anything when receive payment notification from PayPal
 
svn_client:
svn update doesn't always restore to correct scroll location (if lots of files)
incremental search in SVNListBase: only search file name
 
Repo tab for "svn list"
drag => svn copy/move (for branching/tagging)
ask for destination name before performing action
 
checkout single selected item
only directories
ask for dest, warn if same name already exists
create new window (see --checkout)
 
refresh selected nodes
find closest directory parent for each selected item
add open subitems to tree's open list and then call Update on each one
 
--checkout [-r rev] url [path]
error if URL is not type dir
warn if same name already exists in dest location
open window for dest dir
only show Repo tab initially
exec in target dir: svn checkout [-r rev] url
display output in SVNCommandLog
when finished, create/refresh Status tab
 
Input field on every action tab
wrapper widget creates JXScrollbarSet and input field
when set process + fd, show input
when process finished, hide input
 
JXMenu::PrepareToOpenMenu()
itsOwner may delete us!
 
Docking
medic dock all windows: resize causes crash because compartments do not conform to min sizes
Gnome/fvwm2 sometimes require dock/undock/dock to get it positioned correctly
is this because JX doesn't give WM time to make adjustments?
Gnome docking:
window sometimes remains on desktop without border
dock window moves when drag window from docking compartment with
other windows to empty docking compartment
Appears to be because Raise() is called twice in a row on the JXDockDirector
 
When compartment minimized and move tab position, should readjust pane sizes
When min page size increases in dock, adjust panes so divider visible
(test: move tab group tabs from side to top)
 
JXWindow:
ignore hide and iconify for docked windows
Before docking, show and deiconify
doesn't work correctly when "all docked" and show iconified window
(e.g., file list)
 
When drag in testjx Dock #3, ghost drawing from something
 
-----
 
Daily Comics:
xkcd:
include title attribute from image
iphone:
scrape each site once per hour (comics.com and other big sites once per day)
for each domain, 1 request per minute
scp results to sourceforge.net
app pulls from sourceforge
 
if skip before loaded, saves prev in that slot
when first open dashboard after reboot, sizes window to back, even when front visible
 
systemg:
optimize selection of multiple items
systemg *.cpp in large directory
locks up when find returns many files
-name *.cpp -o -name *.h -o -name *.xpm
 
store alternate-open prefs for every executable in the directory
use these prefs when plain-open is invoked
when open prefs file for directory, flush non-existent executables
 
trash must remember where each file came from
~/.trash/.source stores list of original locations
cull non-existent when re-write the file
delete when empty trash
 
medic:
CMLineNumberTable
need helper to set bp condition -- different for each debugger
gdb
crash when open examine memory window -- disabled temporarily
DND for breakpoints -- moves associated commands, conditions, etc.
 
Same prefs menu in all windows
set commands when restore breakpoints
need to store commands
 
leibnitz
finish 3D plotting
latent pg for eval?
Add tip-of-the-day with editing shortcuts like space, fn names, etc.
scale axes to fit range
allow range to be away from origin
edit axis scale: min, max, delta
 
multi-pane editing:
split off itsBuffer,itsStyles,itsUndo/RedoList into JTextBuffer
leave recalc engine, cursor location, and other display stuff in JTextEditor
JTextEditor can be constructed from string or JTextBuffer
CBTextEditor has handle to {JTextBuffer, refCount}
Edit menu has "New view..." which opens another CBTextEditor and incr refCount
When close, only require save if refCount == 1
Active undo needs to know which view it is for
since event from another view needs to deactivate it and create new one
 
Mondrian:
build
string list
main window with single, generic widget type
create by dragging from palette
class name
widget renders based on class name
button with ^M => return button
tab complete in class name input field
menu next to class name input field with known types
x,y,w,h
text (enabled for some types)
shortcuts
sizing
variable name
ctor arguments
palette
just another layout window
save in prefs -- allows rearranging, resizing, custom objects, etc
import from .fd
load/save own format
 
main window is sorted JXStringList
hash table stores serialized layouts
open item from main window => look up and deserialize into layout
JXLayoutCanvas contains tree of JXLayoutObject
JXLayoutObject has option to accept drop to create child node
layout window options
show rulers/grid
snap to grid (5,10,other)
align selected: top,bottom,center; right,left,center
outline bounding rects
need option to control tab order
show index in each item
cmd-click to select item without re-ordering
click to make object the next in list
resize object: only show corner handles if object very small
special object for JXTabGroup, to allow direct editing of all cards
sizing references
http://developer.apple.com/documentation/DeveloperTools/Conceptual/IB_UserGuide/Introduction/chapter_1_section_1.html
http://www.reportmill.com/ribs/support/layout-management/
localization
store separate copy of layout for each locale (en_US, en_GB, fr_FR, fr_CA, ...)
when create or delete, apply to all locales
generated code pulls strings *and* x,y,w,h
menu in editor window to choose locale
resizes and replaces contents with locale's layout
sizing
fixedLeft, fixedRight, elastic
floatingCenter, proportional
fixedLeftProportional, fixedRightProportional
 
jcc:
implement *not* "one a a time" for commands
when invoke one-at-a-time from not-one-at-a-time, invoke separate loop
when invoke @ commands, must treat as one-at-a-time
After rename file, check open projects and update
import/export Task menu contents
search results: option to show n lines above and below matching line
 
Pick a default size and location for text windows when first run
based on desktop size (if not auto-dock all)
Same prefs menu in all windows
 
multi-project
open all .jcc files and display in one tree
.jmp file stores list of .jcc files (relative or home or absolute paths)
merge search paths and build separate .jst file
separate .jup file
Tooltip-like window when open function arg list
bold current argument, based on number of commas after opening paren
Tooltip for scrolltabs: which function it is in
Tooltip while scrolling: which function it is in
PHP styler:
falls out of PHP mode when it sees ?>
while editing string, it may find ?> that should be inside string
PHP class tree
tabs/spaces:
search up in directory tree until find .project_modeline
parse some standard format to get tabs/spaces settings
publish as open protocol on newplanetsoftware.com
 
perl: = 2 ?
Delete 2, type 2 => styles are wrong to next ?
Same with /, because both are regex constructs
Need to restyle further?
 
When search for something in CVS output window, doesn't hilight selection
until wheel-mouse scroll.
 
When cvs diff is run in directory with .jcc file, loses data from middle of
.jcc contents to some later point -- only seen on work machine, and only
with old single, line format
 
CBTreeDirector:
ReceiveWithFeedback: include src file for C++
Editor for regex's so compiler support is not hard-coded
Cascade option for undocked windows
Option to search all files in current project
Symbol list: print unique prefix for file names (like in Files window)
PHP: balance <? ?>
JXChooseMonoFont: allow "Other..."
 
Class trees need to search symbol database for function location.
 
takes a long time to figure out that a 251MB file is large enough to
warn about -- is the underlying code somehow reading the file to figure out
how big it is?
 
drakon:
FreeBSD missing
size, resident, share
utime, stime always zero
 
filter input, like jcc file list
 
re-nice dialog: slider
if 0, default 19
else, default 0
 
SendSignal dialog
 
buzzer:
merge code from Glenn and get it to build
 
Clean up prefs
JXPrefsDialog has tree list and card file
tree list pane adjusts width to bounds of tree list
card file pane sets min size to union of card sizes
Split CBTextEditorPrefs into multiple panes
factor out JXEditStylesWidget from JXEditStylesDialog so it can be a card
 
Dock
Key shortcuts to move between dock compartments
What key? Tab is fully loaded in jcc
cycle through leaf nodes of tree from left to right
(first, build array of leaf nodes, then find current pane and switch to next)
 
JXHelpDirector:
Add forward and backward buttons/menus
Middle-click on link => new window
Right-click on link => menu
"Open %k Left-click | Open in new window %k Middle-click"
 
JPrefsManager:
Atomic lock around SaveToDisk(), etc. in case multiple instances try writing
 
JTextEditor::DrawInMargin
line #'s
bookmarks -- easier to see which line was marked
 
Char set:
preserve modified char set when font changes
 
-----
 
Windows:
Replace S_ISLNK with check for .lnk
Test usage of R/W/X_OK
Replace X_OK and S_IXUSR with check for .exe/.com?
Build source distr
generate *L.cpp & *Y.cpp before taring source
update misc/win32/regex.h
Test JStringMapDelete & JPtrArrayCopy
JMDIServer:
use TCP socket instead of UNIX socket
write file in /tmp with pid and local port
 
theme:
each widget looks for its function in all loaded theme dlls
start with JXButton
jXGlobals loads all ddls in theme directory that start with theme ID
http://www.newplanetsoftware/jx/theme.php
 
widget factory:
JX defines function pointer and sets it to JX widget factory
other library installs its function pointer and saves original => linked list
object model:
query available values on any object
query value by name on any object
object constructor initializes hash table of get/set function pointers
in base class JXWidget
need generalized object to contain values for get/set
 
-----
 
XML editor
xmltree_source-1.0.0.tar.gz
 
What my program does is parse the xml and create a tree of nodes whose
styles are contextual. Clicking on a node takes you to that line in
jcc. The are two other cmd-click operations that take you to the end of
the xml node or that select the entire node.
 
Xml is just text, so it just didn't make sense to me to create a new
different sort of text editor. I thought this approach made sense.
 
For pure XML, it makes more sense to edit directly in the tree,
however.
 
For the stuff I was doing, writing docbook stuff, the current method
seemed to make the most sense. If it is just simple strings, however, I
can imagine that it would make more sense to deal with it inline. You
might want to keep in mind what I needed it for so whatever changes you
make still make sense in that context. For example, if I'm editing in
jcc and I make a change in the xml editor, do I need to reload the file
in jcc?
 
I'll make separate types for XML formatted text and pure XML. The
former will use your method, while the latter will stick to the tree.
 
Once integrated, the former method will rebuild the XML tree when the
text changes. This is manual in the current version.