Enhance layout of the preferences dialog
This commit is contained in:
parent
08a4aeff7b
commit
735e17a8cb
@ -282,6 +282,10 @@ register('colors.female-dead', ['#feccf0', '#3a292b'])
|
||||
register('colors.unknown-alive', ['#f3dbb6', '#75507B'])
|
||||
register('colors.unknown-dead', ['#f3dbb6', '#35103b'])
|
||||
register('colors.family', ['#eeeeee', '#454545'])
|
||||
register('colors.family-married', ['#eeeeee', '#454545'])
|
||||
register('colors.family-unmarried', ['#eeeeee', '#454545'])
|
||||
register('colors.family-civil-union', ['#eeeeee', '#454545'])
|
||||
register('colors.family-unknown', ['#eeeeee', '#454545'])
|
||||
register('colors.family-divorced', ['#ffdede', '#5c3636'])
|
||||
register('colors.home-person', ['#bbe68a', '#304918'])
|
||||
register('colors.border-male-alive', ['#1f4986', '#171d26'])
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -53,7 +53,7 @@ from gi.repository import Gdk
|
||||
#-------------------------------------------------------------------------
|
||||
from gramps.gen.const import GRAMPS_LOCALE as glocale
|
||||
_ = glocale.translation.gettext
|
||||
from gramps.gen.lib import EventType, EventRoleType
|
||||
from gramps.gen.lib import EventType, EventRoleType, FamilyRelType
|
||||
from gramps.gen.lib.person import Person
|
||||
from gramps.gen.constfunc import has_display, is_quartz, mac, win
|
||||
from gramps.gen.config import config
|
||||
@ -488,8 +488,22 @@ def color_graph_family(family, dbstate):
|
||||
EventRoleType.PRIMARY)):
|
||||
return (config.get('colors.family-divorced')[scheme],
|
||||
config.get('colors.border-family-divorced')[scheme])
|
||||
return (config.get('colors.family')[scheme],
|
||||
config.get('colors.border-family')[scheme])
|
||||
|
||||
fam_rel_type = family.get_relationship()
|
||||
|
||||
family_color = config.get('colors.family')[scheme]
|
||||
border_color = config.get('colors.border-family')[scheme]
|
||||
|
||||
if fam_rel_type == FamilyRelType.MARRIED:
|
||||
family_color = config.get('colors.family-married')[scheme]
|
||||
elif fam_rel_type == FamilyRelType.UNMARRIED:
|
||||
family_color = config.get('colors.family-unmarried')[scheme]
|
||||
elif fam_rel_type == FamilyRelType.CIVIL_UNION:
|
||||
family_color = config.get('colors.family-civil-union')[scheme]
|
||||
elif fam_rel_type == FamilyRelType.UNKNOWN:
|
||||
family_color = config.get('colors.family-unknown')[scheme]
|
||||
|
||||
return (family_color, border_color)
|
||||
|
||||
def color_graph_box(alive=False, gender=Person.MALE):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user