Bug Affects Windows only.
Adds text labels to icons which will only appear in the overflow
dropdown menu when dialog is too narrow. Icons still don't show
due to Gtk bug on Windows, but at least user sees the text labels.
Also deals with problems caused by fix; sometimes do need to load
some other toplevel objects.
In some cases, it was easier to remove unused toplevel objects from
glade files.
This is a workaround for
https://bugzilla.gnome.org/show_bug.cgi?id=644927
What is happening, is that our UndoableEntry class is connecting
to the 'insert-text' event, which uses one of the 'in-out'
parameters for the position of the cursor in the buffer. The very
fact of the connect to the event causes the issue, not something
Gramps is doing wrong.
- Files not closed
- Note text set to 'list' instead of 'str' types
- Address structure elements set to 'None' instead of ''
- Long text strings losing characters and getting corrupted
Another HandleError issue; Also, the Quick report that started was
actually the wrong one, due to a typo in the quickview.gpr.py.
I also rediscovered the bug 6352; and its relationship to quickreports.
When using deep relationship filters on the person tree view with a
large tree, the tree redraw can take a long time (hours). The
DeepRelationshipPathBetween 'prepare' method was getting called for
every person in the preceding filter. And that it also ran through
every person in the db within the prepare method. Resulting in time
as a square function of number of people.
Change view code so that 'prepare' method is called once, and 'apply'
method is called once with list of handles to scan, rather than both
called once per handle.
During Gramps startup, it is possible to start two modal dialogs;
the 'Family Trees' and the 'Update Addons' (when preferences is set
to check on startup). Both are modal.
This upgrades the Window manager and ManagedWindow to support this
case. If this occurs, then the most recent modal window is left
that way, a previous modal window is temporarily downgraded to
non-modal, and the newest window is set 'transient' for the previous
modal window, even if it was not the parent.
This means that there can be only one modal window, and it is always
on top and active.
This change was initiated to correct status bar and popup dialogs
that were coming up in the wrong place under Windows.
Upgrade to Managedwindow allows for size/position config, correct
popup of subordinate dialogs, and better window management in
relation to other dialogs.
The Glade change allows the transient parent function to work.
Note that UpdateAddons remains a modal dialog.
While performing a Merge Family that results in an error, the Error
dialog appears as normally initially.
However, if the user switches to another application and back, the
Error dialog can disappear (it is under the Merge dialog in the UI).
The mouse cannot clear this up (although the keyboard 'enter' or
'Esc' keys will be directed to the Error dialog and close everything.
Originally the progress bar and associated text was shown on the
summary page, but it was never seen since it was shown during the
Gtk assistant 'prepare' stage, before the page was shown.
Unmanaged dialogs are often called for errors, warnings, info etc.
On Windows, If called from a modal parent window, they can be a bit
confusing, since the parent window appears to still be active. This
fix makes the parent window non-modal for the duration of the dialog,
and then returns it to its original state.
Certain multiple commit transactions can leave the db in an inconsistent
state in between commits. If signals are emitted at each commit, GUI
elements can see the inconsistent state and report errors. This fix
delays the signal emission until all the commits are complete, presuming
that the db is consistent before and after the complete transaction.
They are pushed to background if background window tooltip appears.
Also, The book list display was not popping up above the dialog
(no transient parent).
So this was a lot of work...
Updated to use lxml, steep learning curve for someone who never examined XML before...
The merge test code needed some updates because it was last used with an older version of the Gramps XML.
Found another bug in the mergefamilyquery code when test started running; another nonetype issue.
Found another bug in the mergepersonquery code when test started running; another nonetype issue.
Couldn't get the subprocess stuff to work right, so changed code to just call Gramps with capture, similar to export_tests. This in turn required that importxml and exportxml be slightly changed to support StringIO redirection of stdin and stdout.
And test_util needed a change to allow stdout to accept an unencoded stream, so I added an option to use BytesIO for this test as well.
Added some code to save input, result, and expected data to files in Gramps temp directory for debugging whenever an error occurred. Easier to use my editor in diff mode than look at the outputs.