HSyntaxHighlighterDialog Class Reference

Class implementing Dialog, which is used to edit HSyntaxHighlighterSettings, it contains list of all HighlightBlock s and QGroupBox with editing panel. More...

#include <HSyntaxHighlighterDialog.h>

Inheritance diagram for HSyntaxHighlighterDialog:

QDialog

List of all members.

Public Member Functions

 HSyntaxHighlighterDialog (QWidget *parent=0)
 Constructor creates UI and initialize slBlocks and mlBlocks with NULL.
 ~HSyntaxHighlighterDialog ()
 Destructor If settings were set, it deletes HighlightBlocks pointed by slBlocks and mlBlocks.
HSyntaxHighlighterSettings getSettings ()
 settings getter This function modify current settings, by copying HighlightBlocks stored, and possibly modified in slBlocks and mlBlocks into settings
void setSettings (HSyntaxHighlighterSettings _settings)
 Set up initial settings This function is used to setup initial settings of HSyntaxHighlighterDialog, it should be used before executing dialog, if you forget about it behavior may be unexpected.

Private Slots

void editedItemChanged (int _number)

Private Member Functions

 HSyntaxHighlighterDialog (const HSyntaxHighlighterDialog &)
void constructBlockList ()

Private Attributes

Ui::HSyntaxHighlighterDialogClass userInterface
 Qt Designer Generated basic UI for this dialog.
HSyntaxHighlighterSettings settings
 Local copy of settings, user edit it, and any time it can be read via getSettings().
SingleLineHighlightBlockslBlocks
 Pointers to single line blocks, used for storing SingleLineHighlightBlock elements copied from settings.
MultiLinesHighlightBlockmlBlocks
 Pointers to multiple line blocks, used for storing MultiLinesHighlightBlock elements copied from settings.
QVector< HighlightBlock * > allBlocks
 QVector of all HighlightBlock pointers from slBlocks and mlBlocks, used with HBSettingsPanel.


Detailed Description

Class implementing Dialog, which is used to edit HSyntaxHighlighterSettings, it contains list of all HighlightBlock s and QGroupBox with editing panel.

Definition at line 24 of file HSyntaxHighlighterDialog.h.


Constructor & Destructor Documentation

HSyntaxHighlighterDialog::HSyntaxHighlighterDialog ( const HSyntaxHighlighterDialog  )  [private]

Copying constructor. Provided to ensure object ISN'T copied.

HSyntaxHighlighterDialog::HSyntaxHighlighterDialog ( QWidget *  parent = 0  ) 

Constructor creates UI and initialize slBlocks and mlBlocks with NULL.

Parameters:
parent Pointer to parent QWidget, used by QDialog constructor

Definition at line 10 of file HSyntaxHighlighterDialog.cpp.

References mlBlocks, slBlocks, and userInterface.

HSyntaxHighlighterDialog::~HSyntaxHighlighterDialog (  ) 

Destructor If settings were set, it deletes HighlightBlocks pointed by slBlocks and mlBlocks.

Definition at line 18 of file HSyntaxHighlighterDialog.cpp.

References mlBlocks, and slBlocks.


Member Function Documentation

void HSyntaxHighlighterDialog::constructBlockList (  )  [private]

Function filling userInterface.HighlightBlocks QListWidget with all HighlightBlocks pointed by allBlocks

Definition at line 71 of file HSyntaxHighlighterDialog.cpp.

References allBlocks, editedItemChanged(), HighlightBlock::getDescription(), HighlightBlock::getName(), and userInterface.

Referenced by setSettings().

void HSyntaxHighlighterDialog::editedItemChanged ( int  _number  )  [private, slot]

Slot called to change edited item, after calling it destroys current userInterface.groupBox and then replaces it with new appropriate HBSettingPanel

Parameters:
_number new HighlightBlock number to edit now.

Definition at line 85 of file HSyntaxHighlighterDialog.cpp.

References allBlocks, and userInterface.

Referenced by constructBlockList().

HSyntaxHighlighterSettings HSyntaxHighlighterDialog::getSettings (  ) 

settings getter This function modify current settings, by copying HighlightBlocks stored, and possibly modified in slBlocks and mlBlocks into settings

Returns:
Possibly modified HSyntaxHighlighter settings.

Definition at line 58 of file HSyntaxHighlighterDialog.cpp.

References mlBlocks, HSyntaxHighlighterSettings::modified, HSyntaxHighlighterSettings::multiLines, settings, HSyntaxHighlighterSettings::singleLine, and slBlocks.

Referenced by HSyntaxHighlighter::editConfig().

void HSyntaxHighlighterDialog::setSettings ( HSyntaxHighlighterSettings  _settings  ) 

Set up initial settings This function is used to setup initial settings of HSyntaxHighlighterDialog, it should be used before executing dialog, if you forget about it behavior may be unexpected.

Parameters:
_settings Initial settings to store in settings

Definition at line 32 of file HSyntaxHighlighterDialog.cpp.

References allBlocks, constructBlockList(), mlBlocks, HSyntaxHighlighterSettings::multiLines, settings, HSyntaxHighlighterSettings::singleLine, and slBlocks.

Referenced by HSyntaxHighlighter::editConfig().


Member Data Documentation

QVector of all HighlightBlock pointers from slBlocks and mlBlocks, used with HBSettingsPanel.

Definition at line 38 of file HSyntaxHighlighterDialog.h.

Referenced by constructBlockList(), editedItemChanged(), and setSettings().

Pointers to multiple line blocks, used for storing MultiLinesHighlightBlock elements copied from settings.

Definition at line 37 of file HSyntaxHighlighterDialog.h.

Referenced by getSettings(), HSyntaxHighlighterDialog(), setSettings(), and ~HSyntaxHighlighterDialog().

Local copy of settings, user edit it, and any time it can be read via getSettings().

Definition at line 35 of file HSyntaxHighlighterDialog.h.

Referenced by getSettings(), and setSettings().

Pointers to single line blocks, used for storing SingleLineHighlightBlock elements copied from settings.

Definition at line 36 of file HSyntaxHighlighterDialog.h.

Referenced by getSettings(), HSyntaxHighlighterDialog(), setSettings(), and ~HSyntaxHighlighterDialog().

Ui::HSyntaxHighlighterDialogClass HSyntaxHighlighterDialog::userInterface [private]

Qt Designer Generated basic UI for this dialog.

Definition at line 34 of file HSyntaxHighlighterDialog.h.

Referenced by constructBlockList(), editedItemChanged(), and HSyntaxHighlighterDialog().


The documentation for this class was generated from the following files:

Generated on Fri Jan 9 00:51:00 2009 for HSyntaxHighlighter by  doxygen 1.5.8