libyui-qt-pkg  2.45.28
YQPkgGenericDetailsView Class Referenceabstract

Abstract base class for details views. More...

#include <YQPkgGenericDetailsView.h>

Inheritance diagram for YQPkgGenericDetailsView:
Collaboration diagram for YQPkgGenericDetailsView:

Public Slots

void showDetailsIfVisible (ZyppSel selectable)
 Show details for the specified package. More...
 
virtual void showDetails (ZyppSel selectable)=0
 Show details for the specified package. More...
 

Public Member Functions

virtual QSize minimumSizeHint () const
 Returns the minimum size required for this widget. More...
 

Static Public Member Functions

static QString htmlStart ()
 starts the html tag and set the style
 
static QString htmlEnd ()
 
static QString htmlHeading (ZyppSel selectable, bool showVersion=false)
 Returns a uniform heading in HTML format for the specified selectable: name and summary or name, version and summary, if 'showVersion' is 'true'.
 
static QString htmlEscape (const QString &plainText)
 Escapes characters special to HTML in a ( plain text ) string, such as: '<' -> '<' '>' -> '>' '&' -> '&'. More...
 
static QString table (const QString &contents)
 Returns a string containing a HTML table with 'contents'.
 
static QString row (const QString &contents)
 Returns a string containing a HTML table row with 'contents'.
 
static QString cell (QString contents)
 Returns a string containing a HTML table cell with 'contents'.
 
static QString cell (int contents)
 
static QString cell (const string &contents)
 
static QString cell (const zypp::Date &date)
 
static QString hcell (QString contents)
 Returns a string containing a HTML table cell with 'contents' for table headers.
 

Protected Slots

void reloadTab (int newCurrent)
 Show data for the last package.
 
virtual void reload ()
 

Protected Member Functions

 YQPkgGenericDetailsView (QWidget *parent)
 Constructor.
 
virtual ~YQPkgGenericDetailsView ()
 Destructor.
 

Protected Attributes

QTabWidget * _parentTab
 
ZyppSel _selectable
 

Detailed Description

Abstract base class for details views.

Handles generic stuff like HTML formatting, Qt slots and display only if this view is visible at all ( it may be hidden if it's part of a QTabWidget ).

Definition at line 58 of file YQPkgGenericDetailsView.h.

Member Function Documentation

◆ htmlEscape()

QString YQPkgGenericDetailsView::htmlEscape ( const QString &  plainText)
static

Escapes characters special to HTML in a ( plain text ) string, such as: '<' -> '<' '>' -> '>' '&' -> '&'.

Returns the escaped string.

Definition at line 192 of file YQPkgGenericDetailsView.cc.

◆ minimumSizeHint()

QSize YQPkgGenericDetailsView::minimumSizeHint ( ) const
virtual

Returns the minimum size required for this widget.

Inherited from QWidget.

Definition at line 135 of file YQPkgGenericDetailsView.cc.

◆ showDetails

virtual void YQPkgGenericDetailsView::showDetails ( ZyppSel  selectable)
pure virtualslot

Show details for the specified package.

Reimplement this in derived classes.

Implemented in YQPkgDependenciesView, YQPkgTechnicalDetailsView, YQPkgChangeLogView, YQPkgDescriptionView, YQPkgFileListView, and YQPkgSelDescriptionView.

◆ showDetailsIfVisible

void YQPkgGenericDetailsView::showDetailsIfVisible ( ZyppSel  selectable)
slot

Show details for the specified package.

Delayed ( optimized ) display if this is embedded into a QTabWidget parent: In this case, wait until this page becomes visible.

Definition at line 116 of file YQPkgGenericDetailsView.cc.

Here is the call graph for this function:

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