[AdgTable] Prefixed internal symbols
[adg.git] / docs / gnu / TODO.xml
blob689231b8b8cc98d3aacad7b9ed61ccdf90b25783
1 <?xml version="1.0"?>
2 <!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
3                          "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
5 <chapter id="TODO">
6 <title>Planned features</title>
7 <subtitle>A very rough roadmap of ADG features implementation</subtitle>
9 <para>The following list is roughly in reversed implementation order. All the
10 improvements must be reflected in the demo programs, where applicable.</para>
12 <simplesect id="TODO.unknown">
13 <title>Road to unknown</title>
15 <para>This is the collection of TODOs that could be applied also after the
16 1.0.0 version has been released. They are usually non-blocking and hard
17 to implement.</para>
19 <itemizedlist mark="circle">
20    <listitem override="disc">Hide the CPML APIs accessible from the CpmlPrimitive interface: use
21    a private struct of function pointers to delegate the job to the
22    different primitives.</listitem>
23    <listitem>Check if the decentralization of the quote is applicable to the angular
24    dimensions too and if it is worth the effort.</listitem>
25    <listitem>The ARROW and TRIANGLE markers should follow the director path that
26    could be a curve. Use the METAPOST solution suggested by John Hobby
27    I don't remember where, that is given <parameter>angle</parameter> and <parameter>size</parameter>, rotate the
28    path by half <parameter>angle</parameter> in both directions, look for intersection with a
29    circle centered at the end of the director path with radius <parameter>size</parameter> and
30    close the resulting path.</listitem>
31    <listitem>Add connectivity feature to AdgModel: enable dependencies of models to
32    external data. Use libgda as sample data provider.</listitem>
33    <listitem>Implement AdgText, a generic text management, using pango.</listitem>
34    <listitem>Add self-intersection API for CPML segments.</listitem>
35    <listitem>Add datum support: for implementation ideas checkout this
36    <ulink url="http://nvl.nist.gov/pub/nistpubs/jres/104/4/html/j44mac.htm">draft</ulink>.</listitem>
37    <listitem>Add a CpmlArc primitive and some API to CpmlCurve to be able to check
38    if a curve is an arc approximation. This gives additional information
39    to do some operation, such as a proper radial quote on a Bézier curve.</listitem>
40    <listitem>Hunt the TODOs in CPML and fill the missing logic.</listitem>
41    <listitem>Improve Bézier offset approximation enabling the choice of approximate
42    a single curve with multiple offset curves.</listitem>
43 </itemizedlist>
45 </simplesect>
47 <simplesect id="TODO.1.0.0">
48 <title>Road to adg-1.0.0</title>
50 <para>The commits in the 0.7 branch should be atomics, that is a succesfull
51 built will be added as a prerequisite for each commit, so bisecting
52 with "git bisect" is usable. The API should be considered almost
53 frozen, new additions are still accepted tough. This is a testing
54 branch: the target is to reach a sufficient quality level to make
55 a 1.0.0 release.</para>
57 <para>These releases should reach the wider audience, according to a niche
58 project such as the ADG canvas. This means to build releases also
59 for different platforms, such as *BSD, OpenSolaris and Windows.</para>
61 </simplesect>
63 <simplesect id="TODO.0.7.0">
64 <title>Road to adg-0.7.0</title>
66 <para>The target of the 0.6 branch is to clean up the code and stabilize the
67 API: the 0.7.0 release will probably be a beta release.</para>
69 <itemizedlist mark="circle">
70    <listitem override="disc">Provide a document with API guidelines take it as the holy bible!
71    All the APIs must comply with the rules of this document.</listitem>
72    <listitem override="disc">Try to cross compile and build a windows binary package. Check out
73    <ulink url="http://ricardo.ecn.wfu.edu/~cottrell/cross-gtk/">Allin suggestions</ulink>
74    for hints.</listitem>
75    <listitem>Add printing support with page setup based on GtkPrintOperation provided
76    by GTK+ 2.10 (hence, always available if GTK+ support is enable).</listitem>
77    <listitem>Expose conventions used by ADG APIs: this is mainly needed to make clear
78    getters must be considered read-only, also when returning non-const
79    values (because object referencing is always allowed).</listitem>
80    <listitem>Add italian localization.</listitem>
81    <listitem>Implement a decent "make check" target, basing the check programs on
82    the test framework of glib. Make this an optional feature, as this
83    framework is based on the too young glib-2.16.0.</listitem>
84    <listitem>Create a separate project called adg-lua to host the lua bindings for
85    the ADG project. Provide a demo similar to adg-demo in lua.</listitem>
86    <listitem>Resolve the TODOs in the adg/ directory: the only missing logic
87    should come from the CPML library (and there the TODO items are
88    bound to the less common use cases).</listitem>
89    <listitem>Provide some binary packages for major distributions, such as an
90    installable demo for Windows, a deb package and an rpm one.</listitem>
91 </itemizedlist>
93 </simplesect>
95 <simplesect id="TODO.0.6.0">
96 <title>Road to adg-0.6.0</title>
98 <para>The target of the 0.5 branch is to provide a usable canvas: with usable
99 it is meant a canvas that can generate fairly completed drawings. The
100 0.5.x releases leading up to 0.6.0 should add all the missing features
101 needed to generate this drawing.</para>
103 <itemizedlist mark="circle">
104    <listitem override="disc">Implement adg_matrix_normalize() to get rid of the scaling component
105    of a matrix: consider the point (0,0) and (1,1) on the identity matrix
106    and force on the matrix to normalize a distance of 1.4142... between
107    the same points by modifying only the xx and yy components.</listitem>
108    <listitem override="disc">Move the custom get_local_matrix() inside AdgEntity and implement a
109    common way to manage local matrix - entity interaction: for instance,
110    if the model is rotated an AdgToyText should rotate accordling but not
111    scale (usually, at least if it is not a text written on the model).</listitem>
112    <listitem override="disc">Implement AdgMarker as an abstract entity: it will be the base class
113    for arrows, ticks, squares, dots and so on.</listitem>
114    <listitem override="disc">Implement AdgArrow as AdgMarker derived entity.</listitem>
115    <listitem override="disc">Implement AdgArrowStyle directly inside the AdgDimStyle class and
116    provides a way to customize the markers.</listitem>
117    <listitem override="disc">Rework the style approach by detaching the slot and type concepts:
118    rename slot to dress and let the door opened to future expansion by
119    breaking the one style = one dress equation.</listitem>
120    <listitem override="disc">Rewrite AdgLDim to use the new marker APIs instead of hardcoding the
121    arrows and calling the deprecated rendering callbacks.</listitem>
122    <listitem override="disc">Implement the extents infrastructure that computes the bounding box
123    of the entities without rendering them.</listitem>
124    <listitem override="disc">Implement the outside arrows in AdgLDim.</listitem>
125    <listitem override="disc">Add AdgADim, the angular dimension.</listitem>
126    <listitem override="disc">Implement AdgEdges, a model that computes the edges of an AdgTrail
127    model and build a CpmlPath containing all the vertical edges.</listitem>
128    <listitem override="disc">Add AdgRDim, the radial dimension.</listitem>
129    <listitem override="disc">Rework styles by using GObject and properties.</listitem>
130    <listitem override="disc">Implement an abstract AdgFillStyle, abstracting the cairo_pattern_t
131    APIs and providing a way to customize filling, similar to what
132    AdgLineStyle does for stroking.</listitem>
133    <listitem override="disc">Add AdgRuledFill, an AdgFillStyle implementation that allows to fill
134    with a serie of parallel lines with customizable angle and distance.</listitem>
135    <listitem override="disc">Add AdgHatch, an entity very similar to AdgStroke but that uses
136    cairo_fill() instead of cairo_stroke().</listitem>
137    <listitem override="disc">Implement the extents also for the path so the AdgHatch entity can work
138    reliable: check if it is better to add new code in CPML or to directly
139    use the functions provided by cairo. (Implemented in CPML as the arc
140    primitive is not native in cairo and it is the only one with some quirks
141    in the extents computation)</listitem>
142    <listitem override="disc">Add labeling feature to the models and let AdgDim and children points
143    be expressed as references to those labeled points instead of using
144    explicit coordinates.</listitem>
145    <listitem override="disc">Add AdgTable, a container for AdgToyText in a framed environment.</listitem>
146    <listitem override="disc">Add AdgTitleBlock, a complex entity in global space used to frame the
147    sheet and show the general drawing data (title, scale, date and so on).</listitem>
148    <listitem override="disc">The dressing feature needs more attention: they are still not well
149    polished and always using the "dress" property will likely give name
150    conflicts: a basic mangling is required.</listitem>
151    <listitem override="disc">Allow the linear dimension to be decentralized by using the pos point
152    as reference and using a dedicated enum instead of a three-state.</listitem>
153    <listitem override="disc">Sanitize the ADG APIs: the public functions must cope with invalid
154    arguments without segmentation faults (without crossing the limits of
155    the C language and of the common sense).</listitem>
156    <listitem override="disc">Provide a decent demo program to show the progress so far, including
157    title block, hatches and various dimensions types: update the website
158    with new (and hopefully more impressive) screenshots.</listitem>
159 </itemizedlist>
161 </simplesect>
163 <simplesect id="TODO.0.5.0">
164 <title>Road to adg-0.5.0</title>
166 <para>The target of the 0.4 branch is to build the base of the canvas:
167 few user visible changes but a quite stable base code. All the
168 main infrastructures should be in place.</para>
170 <itemizedlist mark="circle">
171    <listitem override="disc">Develop a basic demo CPML program to visually check the results.</listitem>
172    <listitem override="disc">Provide CPML APIs for accessing cairo paths and browse their segments
173    (a contiguous line segment).</listitem>
174    <listitem override="disc">Provide CPML APIs for accessing segments and browse their primitives
175    (a single line / curve / close path).</listitem>
176    <listitem override="disc">CPML APIs to offset cairo paths: specifically, a decent
177    approximation for single Bézier curves must be implemented.</listitem>
178    <listitem override="disc">Implement APIs to get intersection points between different primitives.</listitem>
179    <listitem override="disc">Provide an abstract API (cpml_segment_intersection?) to compute the
180    intersection points between two segments. To be evaluated the way to
181    return the results (maybe using an argument to specify the maximum
182    number of intersections to return).</listitem>
183    <listitem override="disc">Generate documentation for CPML.</listitem>
184    <listitem override="disc">Merge ldim and adg-demo into a single demo program, basing the user
185    interface on GtkBuilder.</listitem>
186    <listitem override="disc">Implement AdgModel as a bare empty class. Move the actual stuff in
187    AdgTitleBlock.</listitem>
188    <listitem override="disc">Add model-view interaction by providing signal propagation from AdgModel
189    to the dependent entities, so when a data changes the entities will be
190    automatically updated.</listitem>
191    <listitem override="disc">Rename AdgPath to AdgStroke, being the latter a stroke representation
192    of a single AdgPath.</listitem>
193    <listitem override="disc">Implement AdgPath as an AdgModel derived class of a conceptual path.
194    Any AdgPath instance could be referenced by one or more entities.</listitem>
195    <listitem override="disc">Add arcs in CPML to transparently support, whenever possible, the
196    conversion between arcs and Bézier curves.</listitem>
197    <listitem override="disc">Add to AdgPath the basic functionality to build a path: basically a
198    bunch of methods emulating the cairo path API but without the need of
199    a yet instantiated cairo context.</listitem>
200    <listitem override="disc">Add support for the CPML arc feature in AdgPath.</listitem>
201    <listitem override="disc">Update the demo using the newly implemented AdgPath to deeply test the
202    model/entity interaction.</listitem>
203    <listitem override="disc">Add a chamfer operation to AdgPath.</listitem>
204    <listitem override="disc">Add a fillet operation to AdgPath.</listitem>
205    <listitem override="disc">Change the matrix entity API, using a cleaner approach.</listitem>
206    <listitem override="disc">Move AdgTranslatable and AdgRotable directly inside AdgEntity.</listitem>
207    <listitem override="disc">Ensure there are no bitfield flags, as they are not binding friendly.</listitem>
208    <listitem override="disc">Change building scripts to get the GTK+ dependency optional.</listitem>
209    <listitem override="disc">Add AdgWidget, a GtkDrawingArea that can accept an AdgCanvas.</listitem>
210    <listitem override="disc">Optimize the implemented entities applying the 0.4 ADG infractrusture
211    and enable caching where applicable.</listitem>
212    <listitem override="disc">Use AdgToyText to draw dimenstion quote where applicable.</listitem>
213    <listitem override="disc">Add a "beyond" property to AdgDimStyle to be used when extending the
214    baseline beyond the extension lines. If not specified, it must default
215    to 3 x arrow size.</listitem>
216    <listitem override="disc">Add a three-state enum to adg-enums.h: ADG_THREE_STATE_OFF,
217    ADG_THREE_STATE_ON and ADG_THREE_STATE_UNKNOWN.</listitem>
218    <listitem override="disc">Add the three-state "outside" property to allow forcing an outside quote.
219    In the default state, the outside must be decided by the space between
220    the extension lines: if greather than 3 x arrow size => inside arrows.</listitem>
221 </itemizedlist>
223 </simplesect>
225 <simplesect id="TODO.0.4.0">
226 <title>Road to adg-0.4.0</title>
228 <para>The target for the 0.3 branch is to give a shape to the project: build
229 system, docs and a bunch of (probably temporary) basic classes should
230 be enough to give a direction.</para>
232 <itemizedlist mark="circle">
233    <listitem override="disc">Split mathematic stuff in its own library. It will be called CPML,
234    that is Cairo Path Manipulation Library.</listitem>
235    <listitem override="disc">Avoid wrapping of cairo APIs in AdgPath.</listitem>
236    <listitem override="disc">Implement AdgToyText, a basic text entity using the cairo "toy" text API.</listitem>
237    <listitem override="disc">Implement AdgTranslatable, a shared interface for entities that
238    can be translated.</listitem>
239    <listitem override="disc">Implement AdgRotable, a shared interface for entities that can be rotated.</listitem>
240 </itemizedlist>
242 </simplesect>
244 </chapter>