Public Member Functions

ToolStrip Class Reference

Widget containing tool buttons. More...

#include <xmlui/toolstrip.h>

List of all members.

Public Member Functions


Detailed Description

Widget containing tool buttons.

This widget can be used as a replacement of the menu bar and toolbars. It displays tool buttons of different size layed out and grouped in sections. The tool strip can be populated with actions using the Builder object.


Constructor & Destructor Documentation

ToolStrip ( QWidget *  parent  ) 

Constructor.

Parameters:
parent The parent widget.
~ToolStrip (  ) 

Destructor.


Member Function Documentation

void setHeaderWidget ( QWidget *  widget  ) 

Set the header widget displayed in the left part of the tool strip.

QWidget * headerWidget (  )  const

Return the header widget.

void addToolAction ( QAction *  action  ) 

Add a tool button associated with given action.

Parameters:
action The action to add.
void addSeparator (  ) 

Add a separator between buttons.

void beginSection ( const QString &  title  ) 

Begin a section containing actions.

Parameters:
title The title of the section.
void endSection (  ) 

End the current section.

void beginGrid (  ) 

Begin a grid layout inside a section.

void endGrid (  ) 

End the current grid layout.

void beginRow (  ) 

Begin a horizontal row of small buttons in a grid layout.

void endRow (  ) 

End the current row.

void clearToolActions (  ) 

Remove all tool buttons and sections.

The header widget and auxiliary actions are not removed.

void addAuxiliaryAction ( QAction *  action  ) 

Add a tool button associated with given action in the top right corner of the tool strip.

Parameters:
action The action to add.
void clearAuxiliaryActions (  ) 

Remove all auxiliary actions.

void setContentsMargins ( int  left,
int  top,
int  right,
int  bottom 
)

Set the margins for tool strip contents.

void execMenu ( QAction *  action  ) 

Execute the popup menu associated with given action.