Public Types | Public Member Functions | Static Public Member Functions | Friends

ToolFlagElement Class Reference

List of all members.

Public Types

enum  ElementType {
  NONE, STATIC, PATH, INPUT_BOX,
  CHECK_BOX, LINE_EDIT, COMBO_BOX, COMBO_OPTION,
  IMAGES, DIR_BUTTON, END
}
enum  SliceCount {
  ALL_BUT_ONE = -2, ALL_SLICES = -1, NO_SLICES = 0, SINGLE_SLICE = 1,
  DOUBLE_SLICE = 2
}

Public Member Functions

 ToolFlagElement (ToolFlag *parent, ToolFlagElement *guiParent)
 ToolFlagElement (ToolFlag *parent, const QString &staticText)
ToolFlagElementClone (ToolFlag *flag, ToolFlagElement *lastComboBox)
void AppendArg (QStringList *args, VolumeIndex *slice, VolumeIndex *nextStack, const QString &fileName, bool first, Tool *tool, QHash< QString, QStringList > &outputFiles)
void Initialize (int &row, ProcessSettings *settings, const QHash< QString, QStringList > &possibleFiles)
void InitializeInputBox (int &row, ProcessSettings *settings, const QStringList &possibleFiles, bool isDefault)
void InitializeCheckBox (int &row, ProcessSettings *settings)
void InitializeComboBox (int &row, ProcessSettings *settings)
void InitializeComboOption ()
void InitializeLineEdit (int &row, ProcessSettings *settings)
void InitializeDirButton (int &row, ProcessSettings *settings)
void DetachFromGui (ProcessSettings *settings)
void UpdateEnabledStatus ()
void AddInputFilesToComboBox (const QStringList &inputFiles)
void LoadFromXml (QXmlStreamReader &xml)
void SaveToXml (QXmlStreamWriter &xml)
bool AppendElement (QStringList *args, VolumeIndex *index, const QString &fileNameOverride, Tool *tool, QHash< QString, QStringList > &outputFiles)
int GetStartEndIndices (bool &ok, int &sliceIdx, const QList< VolumeIndex * > &slices)
void ConnectCheckboxSignal (ToolFlag *flag, const QString &type)
void ConnectInputBoxSignal (ToolFlag *flag, const QString &type)
void DisableGuiObject ()

Static Public Member Functions

static ToolFlagElementCreateFromXml (ToolFlag *parent, ToolFlagElement *guiParent, QXmlStreamReader &xml)
static bool ControlGreaterThan (int lhs, int rhs)

Friends

ToolFlagToolFlag::Clone ()
int ToolFlag::GetMaxControlCount ()

Member Function Documentation

void ToolFlagElement::LoadFromXml ( QXmlStreamReader &  xml )

Reads the ToolFlagElement from xml. Used in connection with ToolFlag. ToolFlagElement consists of the different types of flags that can be used. Some require user input, others do not.

All flags support the following flags.

  • control - Appends output from control section, if value is greater than [1], multiple control sections will be appended. If value is [-1] all sections will be appended. If value is [-2], all but one section will be appended. Default value [0].
  • slices - When set to [-1] output from all children slices of the section will be appended.
  • channel - The specific channel to run the arguments on.
Element Types
  • InputBox - User selected input box. Searches for all input matching Tool's input flags, and builds a combo box of selections.
    • tag - Allows to select a different set of input filters than the default.
  • Static - Automatically append the static value. No user interaction. Supports all custom symbols, see Slice::ReplaceSymbols().
  • ComboBox - Generates a combo box from the options that the user is allowed to modify.
    • Option - A single combo box option. The value is appended after the flag.
  • CheckBox - A checkbox with the given text as it's label.
  • CheckBox - A line edit with the given text as it's label.
    • validator - Verifies the input with a validator, valid validators are int, double, percentorint, and percent.


The documentation for this class was generated from the following files:
 All Classes Functions Variables