MessageList::Core::Theme::Column

MessageList::Core::Theme::Column Class Reference

#include <theme.h>

Classes

class  SharedRuntimeData
 

Public Member Functions

 Column ()
 
 Column (const Column &src)
 
 ~Column ()
 
void addGroupHeaderRow (Row *row)
 
void addMessageRow (Row *row)
 
bool containsTextItems () const
 
bool currentlyVisible () const
 
double currentWidth () const
 
void detach ()
 
const QList< Row * > & groupHeaderRows () const
 
void insertGroupHeaderRow (int idx, Row *row)
 
void insertMessageRow (int idx, Row *row)
 
bool isSenderOrReceiver () const
 
const QStringlabel () const
 
bool load (QDataStream &stream, int themeVersion)
 
const QList< Row * > & messageRows () const
 
SortOrder::MessageSorting messageSorting () const
 
const QStringpixmapName () const
 
void removeAllGroupHeaderRows ()
 
void removeAllMessageRows ()
 
void removeGroupHeaderRow (Row *row)
 
void removeMessageRow (Row *row)
 
void save (QDataStream &stream) const
 
void setCurrentlyVisible (bool currentlyVisible)
 
void setCurrentWidth (double currentWidth)
 
void setIsSenderOrReceiver (bool sor)
 
void setLabel (const QString &label)
 
void setMessageSorting (SortOrder::MessageSorting ms)
 
void setPixmapName (const QString &pixmapName)
 
void setVisibleByDefault (bool vbd)
 
bool visibleByDefault () const
 

Detailed Description

The Column class defines a view column available inside this theme.

Each Column has a list of Row items that define the visible rows.

Definition at line 504 of file theme.h.

Constructor & Destructor Documentation

Theme::Column::Column ( )
explicit

Create an empty column with default settings.

Definition at line 611 of file theme.cpp.

Theme::Column::Column ( const Column src)
explicit

Create an exact copy of the column src.

The shared runtime data is not copied (only a reference is added). If you need to create an independent clone then please use detach() after the construction.

Definition at line 620 of file theme.cpp.

Theme::Column::~Column ( )

Kill a column object.

Definition at line 639 of file theme.cpp.

Member Function Documentation

void Theme::Column::addGroupHeaderRow ( Theme::Row row)

Appends a group header row to this theme.

The Theme takes the ownership of the Row pointer.

Definition at line 753 of file theme.cpp.

void Theme::Column::addMessageRow ( Theme::Row row)

Appends a message row to this theme column.

The Theme takes the ownership of the Row pointer.

Definition at line 741 of file theme.cpp.

bool Theme::Column::containsTextItems ( ) const

Returns true if this column contains text items.

This is useful if you want to know if the column should just get its minimum allowable space or it should get more.

Definition at line 791 of file theme.cpp.

bool Theme::Column::currentlyVisible ( ) const

Returns the current shared visibility state for this column.

This state is shared between all the instances of this theme.

Definition at line 709 of file theme.cpp.

double Theme::Column::currentWidth ( ) const

Returns the current shared width setting for this column or -1 if the width is not specified and should be auto-determined.

This state is shared between all the instances of this theme.

Definition at line 719 of file theme.cpp.

void Theme::Column::detach ( )

Detaches the shared runtime data object and makes this object totally independent.

The shared runtime data is initialized to default values.

Definition at line 688 of file theme.cpp.

const QList< Theme::Row * > & Theme::Column::groupHeaderRows ( ) const

Returns the list of rows visible in this column for a GroupHeaderItem.

Definition at line 772 of file theme.cpp.

void Theme::Column::insertGroupHeaderRow ( int  idx,
Row row 
)

Inserts a group header row to this theme column in the specified position.

The Theme takes the ownership of the Row pointer.

Definition at line 777 of file theme.cpp.

void Theme::Column::insertMessageRow ( int  idx,
Row row 
)

Inserts a message row to this theme column in the specified position.

The Theme takes the ownership of the Row pointer.

Definition at line 758 of file theme.cpp.

bool Theme::Column::isSenderOrReceiver ( ) const

Returns true if this column is marked as "sender/receiver" and we should update its label on-the-fly.

Definition at line 668 of file theme.cpp.

const QString & Theme::Column::label ( ) const

Returns the label set for this column.

Definition at line 648 of file theme.cpp.

bool Theme::Column::load ( QDataStream stream,
int  themeVersion 
)

Handles column loading (used by Theme::load())

Definition at line 835 of file theme.cpp.

const QList< Theme::Row * > & Theme::Column::messageRows ( ) const

Returns the list of rows visible in this column for a MessageItem.

Definition at line 729 of file theme.cpp.

SortOrder::MessageSorting Theme::Column::messageSorting ( ) const

Returns the sort order for messages that we should switch to when clicking on this column's header (if visible at all).

Definition at line 699 of file theme.cpp.

const QString & Theme::Column::pixmapName ( ) const

Returns the icon's name (used in SmallIcon) set for this column.

Definition at line 658 of file theme.cpp.

void Theme::Column::removeAllGroupHeaderRows ( )

Removes all the group header rows from this column.

Definition at line 746 of file theme.cpp.

void Theme::Column::removeAllMessageRows ( )

Removes all the message rows from this column.

Definition at line 734 of file theme.cpp.

void Theme::Column::removeGroupHeaderRow ( Theme::Row row)

Removes the specified group header row.

The row is NOT deleted.

Definition at line 786 of file theme.cpp.

void Theme::Column::removeMessageRow ( Theme::Row row)

Removes the specified message row.

The row is NOT deleted.

Definition at line 767 of file theme.cpp.

void Theme::Column::save ( QDataStream stream) const

Handles column saving (used by Theme::save())

Definition at line 806 of file theme.cpp.

void Theme::Column::setCurrentlyVisible ( bool  currentlyVisible)

Sets the current shared visibility state for this column.

This state is shared between all the instances of this theme.

Definition at line 714 of file theme.cpp.

void Theme::Column::setCurrentWidth ( double  currentWidth)

Sets the current shared width setting for this column.

This state is shared between all the instances of this theme.

Definition at line 724 of file theme.cpp.

void Theme::Column::setIsSenderOrReceiver ( bool  sor)

Marks this column as containing the "sender/receiver" field.

Such columns will have the label automatically updated.

Definition at line 673 of file theme.cpp.

void Theme::Column::setLabel ( const QString label)

Sets the label for this column.

Definition at line 653 of file theme.cpp.

void Theme::Column::setMessageSorting ( SortOrder::MessageSorting  ms)

Sets the sort order for messages that we should switch to when clicking on this column's header (if visible at all).

Definition at line 704 of file theme.cpp.

void Theme::Column::setPixmapName ( const QString pixmapName)

Sets the icon's name (used in SmallIcon) for this column.

Definition at line 663 of file theme.cpp.

void Theme::Column::setVisibleByDefault ( bool  vbd)

Sets the "visible by default" tag for this column.

Definition at line 683 of file theme.cpp.

bool Theme::Column::visibleByDefault ( ) const

Returns true if this column has to be shown by default.

Definition at line 678 of file theme.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Sun Aug 2 2020 23:12:04 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.