Back to index

scribus-ng  1.3.4.dfsg+svn20071115
Public Member Functions | Private Slots | Private Member Functions | Private Attributes
SMShadeButton Class Reference

#include <smwidgets.h>

List of all members.

Public Member Functions

 SMShadeButton (QWidget *parent)
 ~SMShadeButton ()
void setValue (int i)
void setValue (int i, bool isParentValue)
void setParentValue (int i)
bool useParentValue ()

Private Slots

void currentChanged ()
void slotUseParent ()

Private Member Functions

void setFont (bool wantBold)

Private Attributes

bool hasParent_
bool useParentValue_
int pValue_

Detailed Description

Definition at line 159 of file smwidgets.h.


Constructor & Destructor Documentation

SMShadeButton::SMShadeButton ( QWidget *  parent)

Definition at line 480 of file smwidgets.cpp.

: ShadeButton(parent),
  hasParent_(false),
  useParentValue_(false),
  pValue_(0)
{
       
}

Definition at line 164 of file smwidgets.h.

{};

Member Function Documentation

void SMShadeButton::currentChanged ( ) [private, slot]

Definition at line 537 of file smwidgets.cpp.

{
       if (hasParent_)
       {
              setFont(true);
              QString upv = tr("Use Parent Value");
              if (FillSh->text(FillSh->idAt(FillSh->count() - 1)) != upv)
                     FillSh->insertItem(upv, this, SLOT(slotUseParent()));
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

void SMShadeButton::setFont ( bool  wantBold) [private]

Definition at line 529 of file smwidgets.cpp.

{
       QFont f(font());
       f.setBold(wantBold);
       FillSh->setFont(f);
       ShadeButton::setFont(f);
}

Here is the caller graph for this function:

Definition at line 508 of file smwidgets.cpp.

{
       hasParent_ = true;
       pValue_ = i;
}

Here is the caller graph for this function:

Definition at line 489 of file smwidgets.cpp.

{
       disconnect(this, SIGNAL(pressed()), this, SLOT(currentChanged()));
       setFont(false);
       hasParent_ = false;
       pValue_ = 0;
       ShadeButton::setValue(i);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void SMShadeButton::setValue ( int  i,
bool  isParentValue 
)

Definition at line 498 of file smwidgets.cpp.

{
       disconnect(this, SIGNAL(pressed()), this, SLOT(currentChanged()));
       hasParent_ = true;
       pValue_ = i;
       setFont(!isParentValue);
       ShadeButton::setValue(i);
       connect(this, SIGNAL(pressed()), this, SLOT(currentChanged()));
}

Here is the call graph for this function:

void SMShadeButton::slotUseParent ( ) [private, slot]

Definition at line 548 of file smwidgets.cpp.

{
       useParentValue_ = true;
       FillSh->removeItemAt(FillSh->count() - 1);
       emit clicked();
}

Here is the caller graph for this function:

Definition at line 514 of file smwidgets.cpp.

{
       bool ret = useParentValue_;
       useParentValue_ = false;

       if (ret)
       {
              setValue(pValue_, true);
              FillSh->removeItemAt(FillSh->count() - 1);
       }
       

       return ret;
}

Here is the call graph for this function:

Here is the caller graph for this function:


Member Data Documentation

Definition at line 174 of file smwidgets.h.

Definition at line 176 of file smwidgets.h.

Definition at line 175 of file smwidgets.h.


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