- move TemplateElement into separate module,
- remove redundant srctemplatelist module,
- fix editsource so source attribute tab updates when template fields are input,
- fix importcsv so it uses map names defined in citeref module,
svn: r22880
- Separate out the GEDCOM template creation. It becomes a separate plugin that can be loaded or not as the user chooses (but it is loaded automatically on upgrade).
- Fixes to allow templates to work even when no templates are loaded (data is input via the Attributes tab not the source template tab).
- Enhance upgrade to include GEDCOM template. The GEDCOM template is automatically loaded when a database that contains sources is upgraded.
- Tidy up unused variables and redundant code.
svn: r22856
1. 6848: citationtreeview corrupts when search bar open and edit occurs
2. avoid critical gdk error by processing events only when window visible :
Gdk-CRITICAL **: gdk_error_trap_pop_internal: assertion `trap != NULL' failed
3. In case of errors with fg_color, enormous amount of error messages. This patch
grabs wrong fg_color, and skips action, avoiding the error messages. Error goes to debug.
svn: r22610
So that they're together with the other resources instead of in
site-package/gramps. Aside from a better source and installation
layout, this makes it easier to bundle them.
svn: r22576
Use math.degrees() / math.radians() where able
Follow-up to CR by Benny:
Removed redundant forced conversion to float, the
from future import division
handles that already. See PEP-238 for details.
draw_text:
Remove manual layout wrapping, use pango Layout logic.
Refactored wrap_truncate_layout from draw_arc_text,
and it's now reused in draw_text, here with CHAR
wrapping mode as opposed to WORD in draw_arc_text.
This replaces the (Unicode-wrong) implementation of
manual char-by-char code with text truncation.
svn: r22569
gramps/gui/utilscairo.py:
new file, currently holds just the warpPath() function,
taken from /usr/share/doc/python-cairo/examples/warpedtext.py,
with explanatory docs added.
gramps/gui/widgets/fanchart.py, class FanChartBaseWidget:
draw_text() method:
previous logic using cairo toy text API didn't support CTL text.
It has been removed, and replaced with a call to a new
method, draw_arc_text().
Flagged a subtle Unicode issue in the remaining old code,
for radial-oriented text, with a FIXME, I'll probably fix it
later as a separate issue.
create_map_rect_to_sector() static method:
create a transform to use with gui.utilscairo.warpPath(),
currently used in draw_arc_text().
Following Benny's code review I have annotated the algorithm
and made it hopefully clear, but I guess it could be reworked
into a better form if re-expressed with stacked transforms /
complex numbers / matrices for easier later maintenance.
Meanwhile I have used the same approach as the older code
in the file, good enough for a patch under this feature request.
The only issue remaining from the code review is whether
the create_map_rect_to_sector() function should be moved
to gui.utilscairo; see the bug thread.
svn: r22548