|
From: | Keith OHara |
Subject: | Re: Avoid repeats of 'staff-affinity' warning; change text. (issue4278058) |
Date: | Mon, 21 Mar 2011 23:18:49 -0700 |
User-agent: | Opera Mail/11.01 (Win32) |
On Mon, 21 Mar 2011 23:06:12 -0700, Joe Neeman <address@hidden> wrote:
Unfortunately, if I protect the assignment to the property with an if (!pure), I am letting the page-breaking planning rely on the user-requested affinities, and then changing them for the page-layout phase. The boolean 'pure' asks explicitly that we keep the state unchanged, but there was always an implicit expectation that certain properties are unchanging.I don't quite understand this comment. The only effect of set_property is to prevent the warning from being triggered more than once per system. In fact, the layout would be completely unchanged even if you removed the whole if(after_affinity > before_affinity) block. So why does it matter if we condition set_property on something?
In a typical case, the effect is after->set_property("staff-affinity", DOWN) and then when get_spacing_spec is called to determine the next spring, working through the (non)staffs in the system, it will look up the staff affinity we just set for use as before_affinity, thus the next spring is changed. The code in the if(after_affinity>before_affinity) block does change the output for the example at the head of issue 1555.
[Prev in Thread] | Current Thread | [Next in Thread] |