35 wxStyledTextCtrl* stc = aCtrl;
37 stc->SetReadOnly(
false );
43 stc->StyleSetForeground( wxSTC_STYLE_DEFAULT, wxSystemSettings::GetColour( wxSYS_COLOUR_WINDOWTEXT ) );
44 stc->StyleSetBackground( wxSTC_STYLE_DEFAULT, wxSystemSettings::GetColour( wxSYS_COLOUR_LISTBOX ) );
46 stc->SetMarginWidth( 1, 0 );
55 int start = stc->GetLength();
66 stc->StartStyling( start );
67 stc->SetStyling( stc->GetLength() - start,
72 stc->SetReadOnly(
true );
wxStyledTextCtrl * m_diff
DIALOG_TEXT_DIFF_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=wxEmptyString, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(780, 560), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
DIALOG_TEXT_DIFF(wxWindow *aParent, const wxString &aTitle, const std::vector< KIGIT::TEXT_DIFF_LINE > &aLines)
static constexpr int STYLE_ADDED
void FillTextDiffControl(wxStyledTextCtrl *aCtrl, const std::vector< KIGIT::TEXT_DIFF_LINE > &aLines)
Fill aCtrl with a line diff, added and removed lines in the diff colours, and make it read only.
static constexpr int STYLE_REMOVED
void FillTextDiffControl(wxStyledTextCtrl *aCtrl, const std::vector< KIGIT::TEXT_DIFF_LINE > &aLines)
Fill aCtrl with a line diff, added and removed lines in the diff colours, and make it read only.