[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Unit selection input



On Wed, 23 Jan 2002, Cyrille Chepelov wrote:

> Le Tue, Jan 22, 2002, à 11:19:47PM -0600, Lars Clausen a écrit:
> 
>> Further delving into properties turn up a problem: The standard
>> properties code doesn't have a pointer to the diagram at all.  Either
>> one will have to be passed down through object_get_props_from_offsets(),
>> or the objects will have to hold a pointer to their diagram, or
>> something else entirely.  Cyrille, do you have any ideas?
> 
> Huh... let me see if I understand the problem.
> 
> You've got a collection of objects, some having length properties (font
> height, whatever). All these properties must display length values in a
> per-diagram configurable unit. Therefore, to know which length, the
> properties must either be provided a pointer to the diagram, or to the
> object which the must hold a pointer to the diagram. Correct ?

Correct.

[...]
> When beginning to type, I was more in favour for 3). Now, the "bunch of
> unrelated struct fields" problem (emphasized by the trouble naming the 
> struct !)problem is strongly pushing me back towards 1) 
> 
> (actually, towards building a two-way navigability in the 
> 
> 	[diagram] ------> * [layer] -------> * [object] 
> 
> link. Seen like that, a pointer from each object back to the layer, and
> from each layer back to the diagram looks like a much less horrible
> solution.  Besides, this even begins to sound actually good: we have the
> position, bounding_box and now layer fields in the object, together they
> completely define the object's (X-Y-W-H-Z) coordinates. This sounds very
> logical to me. Besides, I see other cool uses, like interesting selection
> modes: select layer by clicking a (non-current layer) object, etc.)

Yes, I am in favor of this as well.  I often find I want bidirectionality
in my data structures.  I shall implement this at once.

-Lars

-- 
Lars Clausen (http://shasta.cs.uiuc.edu/~lrclause)| Hårdgrim of Numenor
"I do not agree with a word that you say, but I   |----------------------------
will defend to the death your right to say it."   | Where are we going, and
    --Evelyn Beatrice Hall paraphrasing Voltaire  | what's with the handbasket?



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] Mail converted by Mofo Magic and the Flying D

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

GuideSMACK