Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(12)  |  Call(8)  |  Derive(0)  |  Import(4)

src/g/r/gramps-3.4.2/src/plugins/lib/libgedcom.py   Gramps(Download)
from QuestionDialog import WarningDialog, InfoDialog
from gen.lib.const import IDENTICAL, DIFFERENT
from gen.lib import (StyledText, StyledTextTag, StyledTextTagType)
 
#-------------------------------------------------------------------------
                    state.msg
        new_note = gen.lib.Note()
        tag = StyledTextTag(StyledTextTagType.FONTFACE, 'Monospace', 
                            [(0, len(message))])
        text = StyledText(message, [tag])

src/g/r/gramps-3.4.2/src/plugins/gramplet/WelcomeGramplet.py   Gramps(Download)
from gui.widgets.styledtexteditor import StyledTextEditor
from gui.widgets import SimpleButton
from gen.lib import StyledText, StyledTextTag, StyledTextTagType
from gen.ggettext import sgettext as _
 
def boldst(text):
    """ Return text as bold styled text
    """
    tags = [StyledTextTag(StyledTextTagType.BOLD, True,
                            [(0, len(text))])]
def linkst(text, url):
    """ Return text as link styled text
    """
    tags = [StyledTextTag(StyledTextTagType.LINK, url,
                            [(0, len(text))])]

src/g/r/gramps-3.4.2/src/plugins/Records.py   Gramps(Download)
#
#------------------------------------------------------------------------
from gen.lib import ChildRefType, Date, EventType, Name, StyledText, \
        StyledTextTag, StyledTextTagType
from gen.plug.docgen import FontStyle, ParagraphStyle, FONT_SANS_SERIF, \
                # Underline call name
                callpos = text.find(n.call)
                tags = [StyledTextTag(StyledTextTagType.UNDERLINE, True,
                            [(callpos, callpos + len(n.call))])]
 

src/g/r/gramps-3.4.2/src/gui/widgets/styledtextbuffer.py   Gramps(Download)
#
#-------------------------------------------------------------------------
from gen.lib import (StyledText, StyledTextTag, StyledTextTagType)
 
#-------------------------------------------------------------------------
                s_ranges = [(start, end+1) for (start, end) in g_ranges]
                s_value = tag.data
                s_tag = StyledTextTag(_('Link'), s_value, s_ranges)
                s_tags.append(s_tag)
            else:
                    if style in ALLOWED_STYLES:
                        s_ranges = [(start, end+1) for (start, end) in g_ranges]
                        s_tag = StyledTextTag(style, s_value, s_ranges)
 
                        s_tags.append(s_tag)

src/g/r/gramps-3.4.2/src/Utils.py   Gramps(Download)
        link_start = text.index(',') + 2
        link_end = len(text) - 1
        tag = gen.lib.StyledTextTag(gen.lib.StyledTextTagType.LINK,
                'gramps://Note/handle/%s' % explanation,
                [(link_start, link_end)])

src/g/r/gramps-3.4.2/src/plugins/import/ImportXml.py   Gramps(Download)
            return
 
        self.note_tags.append(gen.lib.StyledTextTag(tagtype, tagvalue))
 
    def start_tag(self, attrs):