View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0015816||Scribus||Properties Palette||public||2019-09-09 13:36||2019-09-09 15:30|
|Priority||normal||Severity||minor||Reproducibility||have not tried|
|Summary||0015816: Scribus suddenly switches to a recent used open document when using the properties palette|
|Description||From time to time, Scribus switches to the last used document when applying formatting from the Properties palette.|
I think that this might be related to:
void PropertiesPalette_Shape::setCurrentItem(PageItem *item)
if (item && !m_doc)
imo, relying on the current action to set the current document might explain the bug and the caller should be sure that the right document is set before setting the current item.
|Tags||No tags attached.|
||Nah, if you look at what PP widgets setDoc() functions do, they have no power to switch document.|
as i wrote in irc, i thin that this check "smells".
if there are reasons why it should be there, i'd really love to see them documented. otherwise, scribus should always be sure that the current document is set, before setting the current item and the check is not needed.
this is how i think the bug could be "hidden" by the check:
- the document switch somehow can happen without clearing the current document in a specific pane
- when activating the tab, the current item gets set but the document is the wrong one
- the action is performed on the item
- the update is performed on the (old) current document and the switch happens.
personally, i'd prefer scribus to crash there and let us fix the bug rather than doing something annoying that we cannot track : - )
that's why, if there are no good reason for the check, i'd prefer to see it removed.
(but -- as said -- there might be a good reason for it! and in that case it should be documented in a comment...)