MCPcopy Create free account
hub / github.com/GilesBathgate/RapCAD / highlightCurrentLine

Method highlightCurrentLine

src/ui/codeeditor.cpp:70–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

68}
69
70void CodeEditor::highlightCurrentLine()
71{
72 QList<QTextEdit::ExtraSelection> extraSelections;
73 if(highlightLine&&!isReadOnly()) {
74 QTextEdit::ExtraSelection selection;
75 selection.format.setBackground(QColor(240,240,240));
76 selection.format.setProperty(QTextFormat::FullWidthSelection, true);
77 selection.cursor = textCursor();
78 selection.cursor.clearSelection();
79 extraSelections.append(selection);
80 }
81 setExtraSelections(extraSelections);
82}
83
84void CodeEditor::setFileName(const QString& f)
85{

Callers

nothing calls this directly

Calls 1

appendMethod · 0.80

Tested by

no test coverage detected