Skip to content

Commit

Permalink
- Shorten the TLM highlighting preview text.
Browse files Browse the repository at this point in the history
- Removed the unused indentOrUnindent slot.

git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@25754 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adeas31 committed Apr 27, 2015
1 parent 70d239c commit fd5af15
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 23 deletions.
11 changes: 0 additions & 11 deletions OMEdit/OMEditGUI/Editors/BaseEditor.cpp
Expand Up @@ -780,17 +780,6 @@ void BaseEditor::toggleBreakpoint()
}
}

/*!
* \brief BaseEditor::indentOrUnindent
* Indents or unindents the code.
* \param doIndent
* \todo For now keep this function in BaseEditor. We should make it a pure virtual and should ask derived classes to implement it.
*/
void BaseEditor::indentOrUnindent(bool doIndent)
{
mpPlainTextEdit->indentOrUnindent(doIndent);
}

/*!
* \class FindReplaceWidget
* Creates a widget within editor for find and replace.
Expand Down
1 change: 0 additions & 1 deletion OMEdit/OMEditGUI/Editors/BaseEditor.h
Expand Up @@ -146,7 +146,6 @@ public slots:
void showTabsAndSpaces(bool On);
void toggleBreakpoint();
virtual void toggleCommentSelection() = 0;
void indentOrUnindent(bool doIndent);
};

class LineNumberArea : public QWidget
Expand Down
15 changes: 4 additions & 11 deletions OMEdit/OMEditGUI/Options/OptionsDialog.cpp
Expand Up @@ -2143,22 +2143,15 @@ TLMEditorPage::TLMEditorPage(OptionsDialog *pOptionsDialog)
mpPreviewPlainTextBox = new QPlainTextEdit;
mpPreviewPlainTextBox->setTabStopWidth(Helper::tabWidth);
QString previewText;
previewText.append("<!-- The root node is the meta-model -->\n"
"<Model Name=\"Pendulum\">\n"
previewText.append("<!-- This is a comment. -->\n"
"<Model Name=\"model\">\n"
"\t<SubModels>\n"
"\t\t<SubModel Name=\"shaft1\"\n"
"\t\t\tStartCommand=\"StartTLMOpenModelica\"\n"
"\t\t\tExactStep=\"0\"\n"
"\t\t\tModelFile=\"shaft1.mo\">\n"
"\t\t<SubModel Name=\"submodel\">\n"
"\t\t</SubModel>\n"
"\t</SubModels>\n"
"\t<Connections>\n"
"\t\t<Connection From=\"shaft1.tlm\" To=\"shaft2.tlm\"\n"
"\t\tDelay=\"1e-4\" Zf=\"1e4\" Zfr=\"1e2\" alpha=\"0.2\"/>\n"
"\t\t<Connection From=\"from\" To=\"to\">\n"
"\t</Connections>\n"
"\t<SimulationParams ManagerPort=\"11113\"\n"
"\t\tStartTime=\"0\"\n"
"\t\tStopTime=\"1\"/>\n"
"</Model>\n");
mpPreviewPlainTextBox->setPlainText(previewText);

Expand Down

0 comments on commit fd5af15

Please sign in to comment.