From 18ac9405661d331456f5bda513712400ada6a355 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Sun, 31 Jan 2016 09:17:35 -0500 Subject: [PATCH] Add labels to SytledText and Note --- gramps/gen/lib/note.py | 13 +++++++++++++ gramps/gen/lib/styledtext.py | 7 +++++++ 2 files changed, 20 insertions(+) diff --git a/gramps/gen/lib/note.py b/gramps/gen/lib/note.py index 92a17bdc5..372da06f6 100644 --- a/gramps/gen/lib/note.py +++ b/gramps/gen/lib/note.py @@ -141,6 +141,19 @@ class Note(BasicPrimaryObject): "private": bool, } + @classmethod + def get_labels(cls, _): + return { + "handle": _("Handle"), + "gramps_id": _("Gramps ID"), + "text": _("Text"), + "format": _("Format"), + "type": _("Type"), + "change": _("Last changed"), + "tag_list": _("Tags"), + "private": _("Private"), + } + @classmethod def from_struct(cls, struct): """ diff --git a/gramps/gen/lib/styledtext.py b/gramps/gen/lib/styledtext.py index 81768f933..374745838 100644 --- a/gramps/gen/lib/styledtext.py +++ b/gramps/gen/lib/styledtext.py @@ -339,6 +339,13 @@ class StyledText(object): "tags": [StyledTextTag], } + @classmethod + def get_labels(cls, _): + return { + "string": _("Text"), + "tags": _("Styled Text Tags"), + } + def unserialize(self, data): """ Convert a serialized tuple of data to an object.