109 f = font.family().encode() |
109 f = font.family().encode() |
110 ps = font.pointSize() |
110 ps = font.pointSize() |
111 weight = -font.weight() |
111 weight = -font.weight() |
112 italic = font.italic() |
112 italic = font.italic() |
113 underline = font.underline() |
113 underline = font.underline() |
|
114 bold = font.bold() |
114 for style in rangeLow + rangeHigh: |
115 for style in rangeLow + rangeHigh: |
115 self.SendScintilla(QsciScintilla.SCI_STYLESETFONT, style, f) |
116 self.SendScintilla(QsciScintilla.SCI_STYLESETFONT, style, f) |
116 self.SendScintilla(QsciScintilla.SCI_STYLESETSIZE, style, ps) |
117 self.SendScintilla(QsciScintilla.SCI_STYLESETSIZE, style, ps) |
117 self.SendScintilla(QsciScintilla.SCI_STYLESETWEIGHT, style, weight) |
118 try: |
|
119 self.SendScintilla(QsciScintilla.SCI_STYLESETWEIGHT, style, weight) |
|
120 except AttributeError: |
|
121 self.SendScintilla(QsciScintilla.SCI_STYLESETBOLD, style, bold) |
118 self.SendScintilla(QsciScintilla.SCI_STYLESETITALIC, style, italic) |
122 self.SendScintilla(QsciScintilla.SCI_STYLESETITALIC, style, italic) |
119 self.SendScintilla(QsciScintilla.SCI_STYLESETUNDERLINE, style, underline) |
123 self.SendScintilla(QsciScintilla.SCI_STYLESETUNDERLINE, style, underline) |
120 |
124 |
121 def linesOnScreen(self): |
125 def linesOnScreen(self): |
122 """ |
126 """ |