Re: pruning "redundant" properties while editing


Subject: Re: pruning "redundant" properties while editing
From: Paul Rohr (paul@abisource.com)
Date: Thu Mar 15 2001 - 14:27:02 CST


Pierre,

Thanks for proposing a concrete scenario. It's tough to work through the
design implications of screw cases like this, and specific examples always
help better understand what's at stake here.

Unfortunately, I see no good way to do a UI which allows you to reach all
the steps in sequence that you describe below. While it sounds
theoretically useful to have it both ways here, I'm just not sure how the UI
would work out in practice.

AFAIK, there are only two user actions available here:

  - make this style ##pt (steps 1, 2, 4)
  - make this selection ##pt (step 3)

The former changes <s props>, the latter changes <c props>. Anytime we have
a collision, we have to choose whether or not to prune any matching /
redundant properties.

Even if it were desirable, I see no good way for the UI to also say:

  - make this selection the default size (step 2a)

Instead, I think we have to make a policy decision and choose which state
transitions make sense and "feel" right.

Now for the gory details.

At 09:54 PM 3/13/01 -0500, Pierre Abbat wrote:
>Would it be possible for the char props to have a "default" value, which
would
>be whatever was set for the style?

For any given property, if it's not explicitly set, then we default back to
what's currently defined in the style. Thus, your "default" value would
have the same semantics as no property at all.

>Let's say you had the following:
><p style="Heading1">Late one <c props="font-size:default">morning</c> in
the <c
>props="font-size:15pt">middle</c> of the night</p>
>and you changed the font-size of Heading1 to 15. Everything would be 15.

1. size markup
   ---- ------
   15 <s name="Heading1" props="font-size:15pt">
   15 morning
   15 <c props="font-size:15pt">middle</c>

Collision A -- explicit props match applied style. We currently allow this.
If pruned, we'd instead have:

1a. size markup
    ---- ------
    15 <s name="Heading1" props="font-size:15pt">
    15 morning
    15 middle

>You
>then change it to 14 and "middle" is still 15.

2. size markup
   ---- ------
   14 <s name="Heading1" props="font-size:14pt">
   14 morning
   15 <c props="font-size:15pt">middle</c>

This only works if we didn't prune collision A.

>You change "middle" to default
>and it's 14.

As mentioned above, there's really no separate UI action to correspond to
this. The only way to wind up in this state is as a direct action of step
2.

2a. size markup
    ---- ------
    14 <s name="Heading1" props="font-size:14pt">
    14 morning
    14 middle

If we don't prune collision A, then you can go from 1-->2, but there's no UI
action to get from 2-->2a.

If we do prune, then you go from 1-->1a immediately, and the action for step
2 actually results in this state (1a-->2a).

>You change "morning" to 14 and nothing visibly changes.

3. size markup
   ---- ------
   14 <s name="Heading1" props="font-size:14pt">
   14 <c props="font-size:14pt">morning</c>
   14 middle

Collision B -- new explicit props match existing style.

>You then
>change Heading1 to 16 and "morning" is still 14 while "middle", being
default,
>is now 16 along with the rest.

4. size markup
   ---- ------
   16 <s name="Heading1" props="font-size:16pt">
   14 <c props="font-size:14pt">morning</c>
   16 middle

This only works if we hadn't pruned collision B.

Paul



This archive was generated by hypermail 2b25 : Thu Mar 15 2001 - 15:25:59 CST