xref: /aoo42x/main/toolkit/doc/layout/notes.txt (revision cdf0e10c)
1--- How layout / hierarchy should work ---
2
3On-screen:
4
5+-------------------+
6| Label:   [Entry]  |
7| - - - - - - - - - |                  |
8|             [ Ok ]|
9+-------------------+
10
11AWT Window hierarcy:
12	Window
13		+ Label
14		+ Entry
15		+ Ok
16
17	ie. unchanged, and backwards compatible - a flat
18representation.
19
20Toolkit Hierachy
21
22	WindowContainer [Bin?]
23		+ Vbox
24			+ HBox
25				+ Label
26				+ Entry
27		+ Alignment
28			+ Ok
29
30	the layout process would happen inside the toolkit code
31(perhaps eventually genericisd itself), and the result from the
32(re-)layout process would be a set of SetPosition/SetSize calls made
33to VCL.
34
35--- code pointers ---
36
37** AWT interfaces:
38    + offapi/com/sun/star/awt/* - eg. XButton.idl
39	+ 'XLayoutConstrains.idl' [ published & mis-named ! ]
40
41    + We can build 'Layout' into the AWT at the toolkit level
42	+ this should be fairly easy, and wouldn't touch VCL much.
43
44** Toolkit (awt) implementation:
45    + toolkit/source/awt/vclxwindows.cxx:
46	+ much of the implementation lurks in here ...
47    + The size information is in 'vclxwindows.cxx' ...
48
49    + toolkit/source/helper/unowrapper.cxx
50	+ factories / code to associate UNO peers with VCL windows
51	+ pWindow->
52
53--- Tests ---
54
55Integration tests:
56    cf. http://www.openoffice.org/issues/show_bug.cgi?id=78747
57
58
59--- more thoughts ---
60
61** Extra Design constraints: [!?]
62	+ accessibility
63	+ QA test-tool-age ... - tests ~will need re-write (unfortunately)
64
65* New functionality we would like:
66	+ ShowAll (vs. Show/Hide) && HideAll ...
67
68Necessary to re- build && deliver svtools/ having delivered toolkit ...
69    rm unxlngi6.pro/slo/textwindowaccessibility.* # first ...
70
71** Layout containers:
72    + XIndexAccess ? - sorted container (?)
73
74* Consider 'XLayoutRoot' top-level ...
75    + inherit from XNameContainer - widgets by name / id ...
76    + hack a VCL dialog ?
77	+ we need a handle we can pass back of some form:
78	+ XWindowPeer getPeer() ... [ can use that I guess ? ]
79    + also need a service interface ?
80	+ or parameters passed as Anys ? [ugh]
81
82* Decided
83    + use 'layout' by itself & small patches
84      to toolkit/ in ooo-build.
85
86* TODO:
87    + need a 'queueResize' method ...
88	+ trigger on show/hide ...
89    + allocateSize should take an awt::Rectangle ...
90    + impl. XLayoutRoot
91    + special cases:
92        + radio-button-group
93	+ notebook
94
95* svx/source/dialog/zoom*
96
97Michael's Todo:
98    + handle MetricField: 'unit' enum etc. - introspection ? or ...
99    + make OK/Cancel buttons function as they should ...
100    + merge layout-svtools.diff into CWS as last step before inclusion ...
101    + FixedLine:
102	+ get sizing right ...
103	+ hook up new virtual methods into toolkit/ (m225) - i#80754
104	+ copy the crud from toolkit's custom vclxwindows.cxx
105	  "calcMinimumSize" logic ...
106    + get ok/help/cancel buttons working ...
107
108    + fix / rationalise property adding in toolkit ...
109	+ simplify it with the new VCLWindow base :-)
110	+ simplify it ...
111	    + spreadsheet ...
112	+ VCLXImageConsumer - can't be instantiated itself
113             anyway ! -> bin the 'true' & just add all these
114	     props unconditionally ...
115
116    + switch construction attributes into their own xmlns to
117      avoid treading on other properties ...
118