Qucs-GUI  0.0.19
Public Slots | Signals | Public Member Functions | Data Fields | Private Slots | Private Attributes
TextDoc Class Reference

The TextDoc class definition. More...

#include <textdoc.h>

Inheritance diagram for TextDoc:
Inheritance graph
[legend]
Collaboration diagram for TextDoc:
Collaboration graph
[legend]

Public Slots

void search (const QString &str, bool CaseSensitive, bool wordOnly, bool backward)
void replace (const QString &str, const QString &str2, bool needConfirmed, bool CaseSensitive, bool wordOnly, bool backward)
void slotCursorPosChanged ()
 TextDoc::slotCursorPosChanged update status bar with line:column.
void slotSetChanged ()
 TextDoc::slotSetChanged togles tab icon to indicate unsaved changes.

Signals

void signalCursorPosChanged (int, int)
void signalFileChanged (bool)
void signalUndoState (bool)
void signalRedoState (bool)

Public Member Functions

 TextDoc (QucsApp *, const QString &)
 TextDoc::TextDoc Text document constructor.
 ~TextDoc ()
 TextDoc::~TextDoc Text document destructor.
void setName (const QString &)
 TextDoc::setName sets the text file name on its tab.
bool load ()
 TextDoc::load loads a text document.
int save ()
 TextDoc::save saves the current document and it settings.
float zoomBy (float)
 TextDoc::zoomBy increases/decreases the text font size.
void showNoZoom ()
 TextDoc::showNoZoom resets the font scaling.
void becomeCurrent (bool)
 TextDoc::becomeCurrent sets text document as current.
bool loadSimulationTime (QString &)
 TextDoc::loadSimulationTime set SimTime member variable.
void commentSelected ()
 TextDoc::commentSelected toggles the comment of selected text See also QucsApp::slotEditActivate.
void insertSkeleton ()
 TextDoc::insertSkeleton adds a basic skeleton for type of text file.
void setLanguage (int)
 TextDoc::setLanguage(int)
void setLanguage (const QString &)
 TextDoc::setLanguage(const QString&)
QString getModuleName (void)
 TextDoc::getModuleName parse the module name ou of the text file contents.
bool loadSettings (void)
 TextDoc::loadSettings loads the text document settings.
bool saveSettings (void)
 TextDoc::saveSettings saves the text document settings .cfg.
void refreshLanguage (void)
QMenu * createStandardContextMenu ()
 TextDoc::createStandardContextMenu creates the standard context menu.

Data Fields

QFont TextFont
bool simulation
QString Library
QString Libraries
QString ShortDesc
QString LongDesc
QString Icon
bool recreate
int devtype
bool SetChanged
int language

Private Slots

void highlightCurrentLine ()
 TextDoc::highlightCurrentLine mark the current line.
bool baseSearch (const QString &, bool, bool, bool)

Private Attributes

SyntaxHighlightersyntaxHighlight

Detailed Description

The TextDoc class definition.

Definition at line 47 of file textdoc.h.


Constructor & Destructor Documentation

TextDoc::TextDoc ( QucsApp App_,
const QString &  Name_ 
)

TextDoc::TextDoc Text document constructor.

Parameters:
App_is the parent object
Name_is the initial text document name

Definition at line 42 of file textdoc.cpp.

Here is the call graph for this function:

TextDoc::~TextDoc Text document destructor.

Definition at line 89 of file textdoc.cpp.


Member Function Documentation

bool TextDoc::baseSearch ( const QString &  str,
bool  CaseSensitive,
bool  wordOnly,
bool  backward 
) [private, slot]

Definition at line 256 of file textdoc.cpp.

Here is the caller graph for this function:

void TextDoc::becomeCurrent ( bool  ) [virtual]

TextDoc::becomeCurrent sets text document as current.

Make sure the menu options are adjusted.

Reimplemented from QucsDoc.

Definition at line 219 of file textdoc.cpp.

Here is the call graph for this function:

TextDoc::commentSelected toggles the comment of selected text See also QucsApp::slotEditActivate.

Definition at line 470 of file textdoc.cpp.

Here is the caller graph for this function:

TextDoc::createStandardContextMenu creates the standard context menu.

Parameters:
pos
Returns:
Todo:
is this working?

Definition at line 354 of file textdoc.cpp.

QString TextDoc::getModuleName ( void  )

TextDoc::getModuleName parse the module name ou of the text file contents.

Returns:
the module name

Definition at line 542 of file textdoc.cpp.

Here is the caller graph for this function:

void TextDoc::highlightCurrentLine ( ) [private, slot]

TextDoc::highlightCurrentLine mark the current line.

Definition at line 573 of file textdoc.cpp.

Here is the caller graph for this function:

TextDoc::insertSkeleton adds a basic skeleton for type of text file.

Definition at line 525 of file textdoc.cpp.

Here is the caller graph for this function:

bool TextDoc::load ( ) [virtual]

TextDoc::load loads a text document.

Returns:
true/false if the document was opened with success

Reimplemented from QucsDoc.

Definition at line 368 of file textdoc.cpp.

Here is the call graph for this function:

bool TextDoc::loadSettings ( void  )

TextDoc::loadSettings loads the text document settings.

Returns:
true/false if settings file opened with success

Definition at line 157 of file textdoc.cpp.

Here is the caller graph for this function:

bool TextDoc::loadSimulationTime ( QString &  Time)

TextDoc::loadSimulationTime set SimTime member variable.

Parameters:
Timestring with simulation time
Returns:
true if SimTime is set

Definition at line 457 of file textdoc.cpp.

Here is the caller graph for this function:

void TextDoc::refreshLanguage ( void  )

Definition at line 592 of file textdoc.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TextDoc::replace ( const QString &  str,
const QString &  str2,
bool  needConfirmed,
bool  CaseSensitive,
bool  wordOnly,
bool  backward 
) [slot]

Definition at line 297 of file textdoc.cpp.

Here is the call graph for this function:

int TextDoc::save ( ) [virtual]

TextDoc::save saves the current document and it settings.

Returns:
true/false if the document was opened with success

clear highlighted lines on save

See also:
MessageDock::slotCursor()

Reimplemented from QucsDoc.

Definition at line 392 of file textdoc.cpp.

Here is the call graph for this function:

bool TextDoc::saveSettings ( void  )

TextDoc::saveSettings saves the text document settings .cfg.

Returns:
true/false if settings file opened with success

Definition at line 129 of file textdoc.cpp.

Here is the caller graph for this function:

void TextDoc::search ( const QString &  str,
bool  CaseSensitive,
bool  wordOnly,
bool  backward 
) [slot]

Definition at line 291 of file textdoc.cpp.

Here is the call graph for this function:

void TextDoc::setLanguage ( int  lang)

TextDoc::setLanguage(int)

Parameters:
langis a language_type Assing value to text document object language variable

Definition at line 120 of file textdoc.cpp.

Here is the caller graph for this function:

void TextDoc::setLanguage ( const QString &  FileName)

TextDoc::setLanguage(const QString&)

Parameters:
FileNameText document file name Extract the file name suffix and assing a language_type to it.

Definition at line 99 of file textdoc.cpp.

Here is the call graph for this function:

void TextDoc::setName ( const QString &  Name_) [virtual]

TextDoc::setName sets the text file name on its tab.

Parameters:
Name_text file name to be set

Reimplemented from QucsDoc.

Definition at line 201 of file textdoc.cpp.

Here is the call graph for this function:

void TextDoc::showNoZoom ( ) [virtual]

TextDoc::showNoZoom resets the font scaling.

Reimplemented from QucsDoc.

Definition at line 443 of file textdoc.cpp.

void TextDoc::signalCursorPosChanged ( int  ,
int   
) [signal]

Here is the caller graph for this function:

void TextDoc::signalFileChanged ( bool  ) [signal]

Here is the caller graph for this function:

void TextDoc::signalRedoState ( bool  ) [signal]

Here is the caller graph for this function:

void TextDoc::signalUndoState ( bool  ) [signal]

Here is the caller graph for this function:

TextDoc::slotCursorPosChanged update status bar with line:column.

Definition at line 321 of file textdoc.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TextDoc::slotSetChanged ( ) [slot]

TextDoc::slotSetChanged togles tab icon to indicate unsaved changes.

Definition at line 334 of file textdoc.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

float TextDoc::zoomBy ( float  s) [virtual]

TextDoc::zoomBy increases/decreases the text font size.

Parameters:
sfont size scaling factor
Returns:
(required) final scale

is the return value being saved on the saveSettings() ?

Reimplemented from QucsDoc.

Definition at line 425 of file textdoc.cpp.

Here is the caller graph for this function:


Field Documentation

Definition at line 76 of file textdoc.h.

QString TextDoc::Icon

Definition at line 74 of file textdoc.h.

Definition at line 79 of file textdoc.h.

Definition at line 71 of file textdoc.h.

Definition at line 70 of file textdoc.h.

Definition at line 73 of file textdoc.h.

Definition at line 75 of file textdoc.h.

Definition at line 78 of file textdoc.h.

Definition at line 72 of file textdoc.h.

Definition at line 69 of file textdoc.h.

Definition at line 101 of file textdoc.h.

Definition at line 67 of file textdoc.h.


The documentation for this class was generated from the following files:
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines