Scribus
Open source desktop publishing at your fingertips
SampleItem Class Reference

Provides sample "text frame" as pixmap. You can create a pixmap with standard Scribus text frame here. It can be used as a kind of preview. More...

#include <sampleitem.h>

Inheritance diagram for SampleItem:
Collaboration diagram for SampleItem:

Public Member Functions

void setText (QString aText)
 Set sample text. More...
 
void setLoremIpsum (int para)
 Use lorem ipsum generator as text source. More...
 
void setBgColor (QColor c)
 Set backgroud color of the pixmap. More...
 
void setBgShade (int c)
 
void setBgColorMgmt (bool enable)
 Set color management for backgroud color of the pixmap. More...
 
void setTxColor (QColor c)
 Set Text color of the pixmap. More...
 
void setTxShade (int c)
 
void setStyle (const ParagraphStyle &aStyle)
 Set whole Scribus paragraph style in one. More...
 
void setLineSpaMode (int lineSpaMode)
 Folowing methods set only one style characteristic.
 
void setLineSpa (double lineSpa)
 
void setTextAlignment (int textAlignment)
 
void setIndent (double indent)
 
void setRightMargin (double indent)
 
void setFirst (double first)
 
void setGapBefore (double gapBefore)
 
void setGapAfter (double gapAfter)
 
void setFont (QString font)
 
void setFontSize (int fontSize, bool autoLineSpa=false)
 Set size of the font. More...
 
void setDrop (bool drop)
 
void setBullet (bool bul)
 
void setNum (bool num)
 
void setDropLin (int dropLin)
 
void setParEffectDist (double dropDist)
 
void setFontEffect (int fontEffect)
 
void setFColor (QString fColor)
 
void setFShade (int fShade)
 
void setSColor (QString sColor)
 
void setSShade (int sShade)
 
void setBaseAdj (bool baseAdj)
 
void setTxtShadowX (int txtShadowX)
 
void setTxtShadowY (int txtShadowY)
 
void setTxtOutline (int txtOutline)
 
void setTxtUnderPos (int txtUnderPos)
 
void setTxtUnderWidth (int txtUnderWidth)
 
void setTxtStrikePos (int txtStrikePos)
 
void setTxtStrikeWidth (int txtStrikeWidth)
 
void setScaleH (int scaleH)
 
void setScaleV (int scaleV)
 
void setBaseOff (int baseOff)
 
void setKernVal (int kernVal)
 
QPixmap getSample (int width, int height)
 Get the sample. More...
 

Detailed Description

Provides sample "text frame" as pixmap. You can create a pixmap with standard Scribus text frame here. It can be used as a kind of preview.

Author
Petr Vanek petr@.nosp@m.yarp.nosp@m.en.cz

Member Function Documentation

QPixmap SampleItem::getSample ( int  width,
int  height 
)

Get the sample.

Parameters
widthW of the sample
heightH of the sample
Return values
QPixmaprendered image
void SampleItem::setBgColor ( QColor  c)

Set backgroud color of the pixmap.

Parameters
ca QColor
void SampleItem::setBgColorMgmt ( bool  enable)

Set color management for backgroud color of the pixmap.

Parameters
enableif color management should be enabled
void SampleItem::setFontSize ( int  fontSize,
bool  autoLineSpa = false 
)

Set size of the font.

Parameters
fontSizefontSize * 10.0 usually
autoLineSpaif true - use automatic line spacing computing
void SampleItem::setLoremIpsum ( int  para)

Use lorem ipsum generator as text source.

Parameters
paracount of the LI paragraphs
void SampleItem::setStyle ( const ParagraphStyle aStyle)

Set whole Scribus paragraph style in one.

Parameters
aStyleParagraph style to set.
void SampleItem::setText ( QString  aText)

Set sample text.

Parameters
aTextQString to set.
void SampleItem::setTxColor ( QColor  c)

Set Text color of the pixmap.

Parameters
ca QColor

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