Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 2261 → Rev 2262

/branches/Version13x/Scribus/scribus/fileloader.cpp
1162,6 → 1162,8
int shX = qRound(QStodouble(it->attribute("CSHX","5")) * 10);
int shY = qRound(QStodouble(it->attribute("CSHY","-5")) * 10);
int outL = qRound(QStodouble(it->attribute("COUT","1")) * 10);
int ulp = qRound(QStodouble(it->attribute("CULP","-0.1")) * 10);
int ulw = qRound(QStodouble(it->attribute("CULW","-0.1")) * 10);
for (uint cxx=0; cxx<tmp2.length(); ++cxx)
{
hg = new ScText;
1189,6 → 1191,8
hg->cshadowx = shX;
hg->cshadowy = shY;
hg->coutline = outL;
hg->cunderpos = ulp;
hg->cunderwidth = ulw;
hg->xp = 0;
hg->yp = 0;
hg->PRot = 0;
1349,6 → 1353,8
currItem->TxtShadowX=qRound(QStodouble(obj->attribute("TXTSHX", "5")) * 10);
currItem->TxtShadowY=qRound(QStodouble(obj->attribute("TXTSHY", "-5")) * 10);
currItem->TxtOutline=qRound(QStodouble(obj->attribute("TXTOUT", "1")) * 10);
currItem->TxtUnderPos=qRound(QStodouble(obj->attribute("TXTULP", "-0.1")) * 10);
currItem->TxtUnderWidth=qRound(QStodouble(obj->attribute("TXTULW", "-0.1")) * 10);
currItem->TxTStyle = QStoInt(obj->attribute("TXTSTYLE", "0"));
currItem->Rot = QStodouble(obj->attribute("ROT"));
currItem->Extra = QStodouble(obj->attribute("EXTRA"));
/branches/Version13x/Scribus/scribus/mpalette.h
292,6 → 292,8
void setStil(int s);
void setAli(int e);
void setShadowOffs(int x, int y);
void setUnderline(int p, int w);
void newUnderline();
void setOutlineW(int x);
void newOutlineW();
void setTScale(int e);
/branches/Version13x/Scribus/scribus/gtaction.cpp
163,6 → 163,8
hg->cshadowx = 50;
hg->cshadowy = -50;
hg->coutline = 10;
hg->cunderpos = -1;
hg->cunderwidth = -1;
hg->cextra = font->getKerning();
hg->cselect = false;
hg->cab = paragraphStyle;
248,6 → 250,8
textFrame->TxtShadowX = 50;
textFrame->TxtShadowY = -50;
textFrame->TxtOutline = 10;
textFrame->TxtUnderPos = -1;
textFrame->TxtUnderWidth = -1;
textFrame->ExtraV = font->getKerning();
}
 
/branches/Version13x/Scribus/scribus/mpalette.cpp
737,6 → 737,8
connect(SeStyle->ShadowVal->Xoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowOffs()));
connect(SeStyle->ShadowVal->Yoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowOffs()));
connect(SeStyle->OutlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newOutlineW()));
connect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
connect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
connect(FreeScale, SIGNAL(clicked()), this, SLOT(ChangeScaling()));
connect(FrameScale, SIGNAL(clicked()), this, SLOT(ChangeScaling()));
connect(Aspect, SIGNAL(clicked()), this, SLOT(ChangeScaling()));
2435,6 → 2437,31
connect(SeStyle->ShadowVal->Yoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowOffs()));
}
 
void Mpalette::newUnderline()
{
int x = qRound(SeStyle->UnderlineVal->LPos->value() * 10.0);
int y = qRound(SeStyle->UnderlineVal->LWidth->value() * 10.0);
if ((HaveDoc) && (HaveItem))
{
ScApp->view->setItemTextUnderline(x, y);
doc->CurrTextUnderPos = x;
doc->CurrTextUnderWidth = y;
emit DocChanged();
}
}
 
void Mpalette::setUnderline(int p, int w)
{
if (ScApp->ScriptRunning)
return;
disconnect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
disconnect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
SeStyle->UnderlineVal->LPos->setValue(p / 10.0);
SeStyle->UnderlineVal->LWidth->setValue(w / 10.0);
connect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
connect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderline()));
}
 
void Mpalette::setOutlineW(int x)
{
if (ScApp->ScriptRunning)
/branches/Version13x/Scribus/scribus/util.cpp
1068,6 → 1068,8
Buffer->TxtShadowX = currItem->TxtShadowX;
Buffer->TxtShadowY = currItem->TxtShadowY;
Buffer->TxtOutline = currItem->TxtOutline;
Buffer->TxtUnderPos = currItem->TxtUnderPos;
Buffer->TxtUnderWidth = currItem->TxtUnderWidth;
Buffer->Rot = currItem->Rot;
Buffer->PLineArt = currItem->PLineArt;
Buffer->PLineEnd = currItem->PLineEnd;
1152,7 → 1154,9
Text += QString::number(currItem->itemText.at(a)->cbase)+'\t';
Text += QString::number(currItem->itemText.at(a)->cshadowx)+'\t';
Text += QString::number(currItem->itemText.at(a)->cshadowy)+'\t';
Text += QString::number(currItem->itemText.at(a)->coutline)+'\n';
Text += QString::number(currItem->itemText.at(a)->coutline)+'\t';
Text += QString::number(currItem->itemText.at(a)->cunderpos)+'\t';
Text += QString::number(currItem->itemText.at(a)->cunderwidth)+'\n';
}
}
Buffer->itemText = Text;
1375,6 → 1379,8
OB->TxtShadowX=qRound(QStodouble(obj->attribute("TXTSHX", "5")) * 10);
OB->TxtShadowY=qRound(QStodouble(obj->attribute("TXTSHY", "-5")) * 10);
OB->TxtOutline=qRound(QStodouble(obj->attribute("TXTOUT", "1")) * 10);
OB->TxtUnderPos=qRound(QStodouble(obj->attribute("TXTULP", "-0.1")) * 10);
OB->TxtUnderWidth=qRound(QStodouble(obj->attribute("TXTULW", "-0.1")) * 10);
OB->Cols = QStoInt(obj->attribute("COLUMNS","1"));
OB->ColGap = QStodouble(obj->attribute("COLGAP","0.0"));
OB->GrType = QStoInt(obj->attribute("GRTYP","0"));
/branches/Version13x/Scribus/scribus/search.cpp
701,6 → 701,8
hg->cshadowx = Doc->CurrTextShadowX;
hg->cshadowy = Doc->CurrTextShadowY;
hg->coutline = Doc->CurrTextOutline;
hg->cunderpos = Doc->CurrTextUnderPos;
hg->cunderwidth = Doc->CurrTextUnderWidth;
hg->cselect = true;
hg->cstyle = Doc->CurrentStyle;
if (RStyle->isChecked())
/branches/Version13x/Scribus/scribus/styleselect.cpp
11,6 → 11,44
 
extern QPixmap loadIcon(QString nam);
 
UnderlineValues::UnderlineValues( QWidget* parent ) : QGroupBox( parent, "ShadowValues" )
{
this->setFrameShape( QGroupBox::NoFrame );
this->setTitle("");
this->setColumnLayout(0, Qt::Vertical );
this->layout()->setSpacing( 0 );
this->layout()->setMargin( 0 );
group1Layout = new QGridLayout( this->layout() );
group1Layout->setAlignment( Qt::AlignTop );
group1Layout->setSpacing( 3 );
group1Layout->setMargin( 0 );
LPos = new MSpinBox( -0.1, 100, this, 1 );
LPos->setValue( -0.1 );
LPos->setWrapping(true);
LPos->setSpecialValueText( tr( "Auto" ) );
LPosTxt = new QLabel( "Displacement", this, "XoffsetTxt" );
group1Layout->addWidget( LPos, 0, 1 );
group1Layout->addWidget( LPosTxt, 0 , 0 );
LWidth = new MSpinBox( -0.1, 100, this, 1 );
LWidth->setValue( -0.1 );
LWidth->setWrapping(true);
LWidth->setSpecialValueText( tr( "Auto" ) );
LWidthTxt = new QLabel( "Linewidth", this, "LWidthTxt" );
group1Layout->addWidget( LWidth, 1, 1 );
group1Layout->addWidget( LWidthTxt, 1 , 0 );
languageChange();
}
 
void UnderlineValues::languageChange()
{
LPos->setSuffix(tr(" %"));
LPosTxt->setText(tr("Displacement"));
LWidth->setSuffix(tr(" %"));
LWidthTxt->setText(tr("Linewidth"));
LPosTxt->adjustSize();
LWidthTxt->adjustSize();
}
 
OutlineValues::OutlineValues( QWidget* parent ) : QGroupBox( parent, "ShadowValues" )
{
this->setFrameShape( QGroupBox::NoFrame );
58,7 → 96,6
YoffsetTxt = new QLabel( "Y-Offset", this, "YoffsetTxt" );
group1Layout->addWidget( Yoffset, 1, 1 );
group1Layout->addWidget( YoffsetTxt, 1 , 0 );
languageChange();
}
 
84,11 → 121,16
buttonGroup3->layout()->setMargin( 0 );
buttonGroup3Layout = new QHBoxLayout( buttonGroup3->layout() );
buttonGroup3Layout->setAlignment( Qt::AlignTop );
UnderlineVal = new UnderlineValues( NULL );
UnderlinePop = new QPopupMenu();
UnderlinePop->insertItem(UnderlineVal);
underlineButton = new QToolButton( buttonGroup3, "underlineButton" );
underlineButton->setText( "" );
underlineButton->setMaximumSize( QSize( 22, 22 ) );
underlineButton->setPixmap(loadIcon("Unter.xpm"));
underlineButton->setToggleButton( true );
underlineButton->setPopup(UnderlinePop);
underlineButton->setPopupDelay(400);
buttonGroup3Layout->addWidget( underlineButton );
underlineWordButton = new QToolButton( buttonGroup3, "underlineButton" );
underlineWordButton->setText( "" );
95,6 → 137,8
underlineWordButton->setMaximumSize( QSize( 22, 22 ) );
underlineWordButton->setPixmap(loadIcon("wordsOnly.png"));
underlineWordButton->setToggleButton( true );
underlineWordButton->setPopup(UnderlinePop);
underlineWordButton->setPopupDelay(400);
buttonGroup3Layout->addWidget( underlineWordButton );
ssLayout->addWidget( buttonGroup3 );
 
/branches/Version13x/Scribus/scribus/serializer.cpp
107,6 → 107,8
hg->cshadowx = it->TxtShadowX;
hg->cshadowy = it->TxtShadowY;
hg->coutline = it->TxtOutline;
hg->cunderpos = it->TxtUnderPos;
hg->cunderwidth = it->TxtUnderWidth;
hg->cextra = 0;
hg->cselect = false;
hg->cab = Absatz;
/branches/Version13x/Scribus/scribus/about.cpp
51,7 → 51,7
tabLayout1->addWidget( pixmapLabel1 );
buildID = new QLabel( tab, "BB" );
buildID->setAlignment(Qt::AlignCenter);
QString bu = tr("%1 %2 %3 ").arg("25").arg("May").arg("2005");
QString bu = tr("%1 %2 %3 ").arg("26").arg("May").arg("2005");
#ifdef HAVE_CMS
bu += "C";
#else
/branches/Version13x/Scribus/scribus/tabtypography.h
33,9 → 33,9
QSpinBox* capsScaling;
QGroupBox* underlineGroup;
QLabel* textLabel1;
QSpinBox* underlinePos;
MSpinBox* underlinePos;
QLabel* textLabel2;
QSpinBox* underlineWidth;
MSpinBox* underlineWidth;
QGroupBox* strikethruGroup;
QLabel* textLabel1_2;
QSpinBox* strikethruPos;
/branches/Version13x/Scribus/scribus/scribusview.h
244,6 → 244,7
void setItemTextBase(int sha);
void setItemTextOutline(int sha);
void setItemTextShadow(int shx, int shy);
void setItemTextUnderline(int pos, int wid);
void ItemBrush(QString farbe);
void ItemBrushShade(int sha);
void ItemPenShade(int sha);
389,6 → 390,7
void ItemTextBase(int);
void ItemTextOutline(int);
void ItemTextShadow(int, int);
void ItemTextUnderline(int, int);
void ItemTextFarben(QString, QString, int, int);
void ItemTextStil(int);
void ItemRadius(double);
/branches/Version13x/Scribus/scribus/charselect.cpp
715,6 → 715,8
hg->cshadowx = ap->doc->CurrTextShadowX;
hg->cshadowy = ap->doc->CurrTextShadowY;
hg->coutline = ap->doc->CurrTextOutline;
hg->cunderpos = ap->doc->CurrTextUnderPos;
hg->cunderwidth = ap->doc->CurrTextUnderWidth;
hg->cselect = false;
hg->cstyle = ap->doc->CurrentStyle;
hg->cab = ap->doc->currentParaStyle;
/branches/Version13x/Scribus/scribus/scribusXml.cpp
167,6 → 167,8
int shX = qRound(QStodouble(it->attribute("CSHX","5")) * 10);
int shY = qRound(QStodouble(it->attribute("CSHY","-5")) * 10);
int outL = qRound(QStodouble(it->attribute("COUT","1")) * 10);
int ulp = qRound(QStodouble(it->attribute("CULP","-0.1")) * 10);
int ulw = qRound(QStodouble(it->attribute("CULW","-0.1")) * 10);
for (uint cxx=0; cxx<tmp2.length(); ++cxx)
{
hg = new ScText;
194,6 → 196,8
hg->cshadowx = shX;
hg->cshadowy = shY;
hg->coutline = outL;
hg->cunderpos = ulp;
hg->cunderwidth = ulw;
hg->xp = 0;
hg->yp = 0;
hg->PRot = 0;
242,12 → 246,16
int shX = qRound(QStodouble(it->attribute("CSHX","5")) * 10);
int shY = qRound(QStodouble(it->attribute("CSHY","-5")) * 10);
int outL = qRound(QStodouble(it->attribute("COUT","1")) * 10);
int ulp = qRound(QStodouble(it->attribute("CULP","-0.1")) * 10);
int ulw = qRound(QStodouble(it->attribute("CULW","-0.1")) * 10);
tmp3 += tmp4.setNum(scale) + "\t";
tmp3 += tmp4.setNum(scalev) + "\t";
tmp3 += tmp4.setNum(base) + "\t";
tmp3 += tmp4.setNum(shX) + "\t";
tmp3 += tmp4.setNum(shY) + "\t";
tmp3 += tmp4.setNum(outL) + "\n";
tmp3 += tmp4.setNum(outL) + "\t";
tmp3 += tmp4.setNum(ulp) + "\t";
tmp3 += tmp4.setNum(ulw) + "\n";
for (uint cxx=0; cxx<tmp2.length(); ++cxx)
tmp += tmp2.at(cxx)+tmp3;
return tmp;
320,6 → 328,8
ob->setAttribute("TXTSHX",item->TxtShadowX / 10.0);
ob->setAttribute("TXTSHY",item->TxtShadowY / 10.0);
ob->setAttribute("TXTOUT",item->TxtOutline / 10.0);
ob->setAttribute("TXTULP",item->TxtUnderPos / 10.0);
ob->setAttribute("TXTULW",item->TxtUnderWidth / 10.0);
ob->setAttribute("TXTSTYLE",item->TxTStyle);
ob->setAttribute("COLUMNS", item->Cols);
ob->setAttribute("COLGAP", item->ColGap);
2055,7 → 2065,7
{
int tsh, tsh2, tst, tst2, tsb, tsb2, tshs, tshs2;
QString text, tf, tf2, tc, tc2, tcs, tcs2, tmp, tmpy;
double te, te2, ts, ts2, tsc, tsc2, tscv, tscv2, tb, tb2, tsx, tsx2, tsy, tsy2, tout, tout2;
double te, te2, ts, ts2, tsc, tsc2, tscv, tscv2, tb, tb2, tsx, tsx2, tsy, tsy2, tout, tout2, tulp, tulp2, tulw, tulw2;
PageItem *item;
QDomDocument docu("scribus");
QString st="<SCRIBUSELEMUTF8></SCRIBUSELEMUTF8>";
2319,6 → 2329,8
tsx = item->itemText.at(k)->cshadowx / 10.0;
tsy = item->itemText.at(k)->cshadowy / 10.0;
tout = item->itemText.at(k)->coutline / 10.0;
tulp = item->itemText.at(k)->cunderpos / 10.0;
tulw = item->itemText.at(k)->cunderwidth / 10.0;
if (item->itemText.at(k)->ch == QChar(13))
text = QChar(5);
else if (item->itemText.at(k)->ch == QChar(9))
2344,6 → 2356,8
it.setAttribute("CSHX",tsx);
it.setAttribute("CSHY",tsy);
it.setAttribute("COUT",tout);
it.setAttribute("CULP",tulp);
it.setAttribute("CULW",tulw);
ob.appendChild(it);
break;
}
2365,6 → 2379,8
tsx2 = item->itemText.at(k)->cshadowx / 10.0;
tsy2 = item->itemText.at(k)->cshadowy / 10.0;
tout2 = item->itemText.at(k)->coutline / 10.0;
tulp2 = item->itemText.at(k)->cunderpos / 10.0;
tulw2 = item->itemText.at(k)->cunderwidth / 10.0;
while ((ts2 == ts)
&& (tsb2 == tsb)
&& (tf2 == tf)
2379,6 → 2395,8
&& (tsx2 == tsx)
&& (tsy2 == tsy)
&& (tout2 == tout)
&& (tulp2 == tulp)
&& (tulw2 == tulw)
&& (tst2 == tst))
{
if (item->itemText.at(k)->ch == QChar(13))
2408,6 → 2426,8
tsx2 = item->itemText.at(k)->cshadowx / 10.0;
tsy2 = item->itemText.at(k)->cshadowy / 10.0;
tout2 = item->itemText.at(k)->coutline / 10.0;
tulp2 = item->itemText.at(k)->cunderpos / 10.0;
tulw2 = item->itemText.at(k)->cunderwidth / 10.0;
}
it.setAttribute("CH",text);
it.setAttribute("CSIZE",ts);
2425,6 → 2445,8
it.setAttribute("CSHX",tsx);
it.setAttribute("CSHY",tsy);
it.setAttribute("COUT",tout);
it.setAttribute("CULP",tulp);
it.setAttribute("CULW",tulw);
k--;
ob.appendChild(it);
}
2498,7 → 2520,7
{
int tsh, tsh2, tst, tst2, tsb, tsb2, tshs, tshs2;
QString text, tf, tf2, tc, tc2, tcs, tcs2, tmp, tmpy, Ndir;
double ts, ts2, te, te2, tsc, tsc2, tscv, tscv2, tb, tb2, tsx, tsx2, tsy, tsy2, tout, tout2;
double ts, ts2, te, te2, tsc, tsc2, tscv, tscv2, tb, tb2, tsx, tsx2, tsy, tsy2, tout, tout2, tulp, tulp2, tulw, tulw2;
uint ObCount = maxC;
PageItem *item;
QDomElement ob;
2574,6 → 2596,8
tsx = item->itemText.at(k)->cshadowx / 10.0;
tsy = item->itemText.at(k)->cshadowy / 10.0;
tout = item->itemText.at(k)->coutline / 10.0;
tulp = item->itemText.at(k)->cunderpos / 10.0;
tulw = item->itemText.at(k)->cunderwidth / 10.0;
if (item->itemText.at(k)->ch == QChar(13))
text = QChar(5);
else if (item->itemText.at(k)->ch == QChar(9))
2599,6 → 2623,8
it.setAttribute("CSHX",tsx);
it.setAttribute("CSHY",tsy);
it.setAttribute("COUT",tout);
it.setAttribute("CULP",tulp);
it.setAttribute("CULW",tulw);
ob.appendChild(it);
break;
}
2617,6 → 2643,8
tsx2 = item->itemText.at(k)->cshadowx / 10.0;
tsy2 = item->itemText.at(k)->cshadowy / 10.0;
tout2 = item->itemText.at(k)->coutline / 10.0;
tulp2 = item->itemText.at(k)->cunderpos / 10.0;
tulw2 = item->itemText.at(k)->cunderwidth / 10.0;
while ((ts2 == ts)
&& (tsb2 == tsb)
&& (tf2 == tf)
2631,6 → 2659,8
&& (tsx2 == tsx)
&& (tsy2 == tsy)
&& (tout2 == tout)
&& (tulp2 == tulp)
&& (tulw2 == tulw)
&& (tst2 == tst))
{
if (item->itemText.at(k)->ch == QChar(13))
2657,6 → 2687,8
tsx2 = item->itemText.at(k)->cshadowx / 10.0;
tsy2 = item->itemText.at(k)->cshadowy / 10.0;
tout2 = item->itemText.at(k)->coutline / 10.0;
tulp2 = item->itemText.at(k)->cunderpos / 10.0;
tulw2 = item->itemText.at(k)->cunderwidth / 10.0;
}
it.setAttribute("CH",text);
it.setAttribute("CSIZE",ts);
2674,6 → 2706,8
it.setAttribute("CSHX",tsx);
it.setAttribute("CSHY",tsy);
it.setAttribute("COUT",tout);
it.setAttribute("CULP",tulp);
it.setAttribute("CULW",tulw);
k--;
ob.appendChild(it);
}
3185,8 → 3219,14
dc3.setAttribute("AUTOL", Vor->typographicSetttings.autoLineSpacing);
dc3.setAttribute("BASE", Vor->typographicSetttings.valueBaseGrid);
dc3.setAttribute("BASEO", Vor->typographicSetttings.offsetBaseGrid);
dc3.setAttribute("UnderlinePos", Vor->typographicSetttings.valueUnderlinePos);
dc3.setAttribute("UnderlineWidth", Vor->typographicSetttings.valueUnderlineWidth);
if (Vor->typographicSetttings.valueUnderlinePos == -1)
dc3.setAttribute("UnderlinePos", Vor->typographicSetttings.valueUnderlinePos);
else
dc3.setAttribute("UnderlinePos", Vor->typographicSetttings.valueUnderlinePos / 10.0);
if (Vor->typographicSetttings.valueUnderlineWidth == -1)
dc3.setAttribute("UnderlineWidth", Vor->typographicSetttings.valueUnderlineWidth);
else
dc3.setAttribute("UnderlineWidth", Vor->typographicSetttings.valueUnderlineWidth / 10.0);
dc3.setAttribute("StrikeThruPos", Vor->typographicSetttings.valueStrikeThruPos);
dc3.setAttribute("StrikeThruWidth", Vor->typographicSetttings.valueStrikeThruWidth);
elem.appendChild(dc3);
3534,8 → 3574,16
Vorein->typographicSetttings.valueBaseGrid = QStodouble(dc.attribute("BASE", "12"));
Vorein->typographicSetttings.offsetBaseGrid = QStodouble(dc.attribute("BASEO", "0"));
Vorein->typographicSetttings.autoLineSpacing = QStoInt(dc.attribute("AUTOL","20"));
Vorein->typographicSetttings.valueUnderlinePos = QStoInt(dc.attribute("UnderlinePos","-1"));
Vorein->typographicSetttings.valueUnderlineWidth = QStoInt(dc.attribute("UnderlineWidth","-1"));
double ulp = QStodouble(dc.attribute("UnderlinePos","-1"));
if (ulp != -1)
Vorein->typographicSetttings.valueUnderlinePos = qRound(ulp * 10);
else
Vorein->typographicSetttings.valueUnderlinePos = -1;
double ulw = QStodouble(dc.attribute("UnderlineWidth","-1"));
if (ulw != -1)
Vorein->typographicSetttings.valueUnderlineWidth = qRound(ulw * 10);
else
Vorein->typographicSetttings.valueUnderlineWidth = -1;
Vorein->typographicSetttings.valueStrikeThruPos = QStoInt(dc.attribute("StrikeThruPos","-1"));
Vorein->typographicSetttings.valueStrikeThruWidth = QStoInt(dc.attribute("StrikeThruWidth","-1"));
}
/branches/Version13x/Scribus/scribus/edit1format.cpp
488,6 → 488,8
hg->cshadowx = 50;
hg->cshadowy = -50;
hg->coutline = 10;
hg->cunderpos = -1;
hg->cunderwidth = -1;
hg->cselect = false;
hg->cstyle = tmpStyle.FontEffect;
hg->cab = tmpIndex;
/branches/Version13x/Scribus/scribus/story.cpp
532,6 → 532,8
hg->cshadowx = CurrTextShadowX;
hg->cshadowy = CurrTextShadowY;
hg->coutline = CurrTextOutline;
hg->cunderpos = CurrTextUnderPos;
hg->cunderwidth =CurrTextUnderWidth;
chars->insert(i, hg);
i++;
}
610,6 → 612,8
hg->cshadowx = cBuffer.at(a)->cshadowx;
hg->cshadowy = cBuffer.at(a)->cshadowy;
hg->coutline = cBuffer.at(a)->coutline;
hg->cunderpos = cBuffer.at(a)->cunderpos;
hg->cunderwidth = cBuffer.at(a)->cunderwidth;
chars->insert(i, hg);
i++;
}
653,6 → 657,8
hg->cshadowx = chars->at(ca)->cshadowx;
hg->cshadowy = chars->at(ca)->cshadowy;
hg->coutline = chars->at(ca)->coutline;
hg->cunderpos = chars->at(ca)->cunderpos;
hg->cunderwidth = chars->at(ca)->cunderwidth;
cBuffer.append(hg);
}
hg = new PtiSmall;
672,6 → 678,8
hg->cshadowx = 50;
hg->cshadowy = -50;
hg->coutline = 10;
hg->cunderpos = -1;
hg->cunderwidth = -1;
cBuffer.append(hg);
}
}
707,6 → 715,8
hg->cshadowx = chars->at(c)->cshadowx;
hg->cshadowy = chars->at(c)->cshadowy;
hg->coutline = chars->at(c)->coutline;
hg->cunderpos = chars->at(c)->cunderpos;
hg->cunderwidth = chars->at(c)->cunderwidth;
}
else
{
724,6 → 734,8
hg->cshadowx = CurrTextShadowX;
hg->cshadowy = CurrTextShadowY;
hg->coutline = CurrTextOutline;
hg->cunderpos = CurrTextUnderPos;
hg->cunderwidth = CurrTextUnderWidth;
if (doc->docParagraphStyles[ParagStyles[p-1]].Font != "")
{
hg->cfont = (*doc->AllFonts)[doc->docParagraphStyles[ParagStyles[p-1]].Font];
760,6 → 772,8
hg->cshadowx = chars->at(c)->cshadowx;
hg->cshadowy = chars->at(c)->cshadowy;
hg->coutline = chars->at(c)->coutline;
hg->cunderpos = chars->at(c)->cunderpos;
hg->cunderwidth = chars->at(c)->cunderwidth;
hg->cselect = false;
hg->xp = 0;
hg->yp = 0;
874,6 → 888,8
hg->cshadowx = nextItem->itemText.at(a)->cshadowx;
hg->cshadowy = nextItem->itemText.at(a)->cshadowy;
hg->coutline = nextItem->itemText.at(a)->coutline;
hg->cunderpos = nextItem->itemText.at(a)->cunderpos;
hg->cunderwidth = nextItem->itemText.at(a)->cunderwidth;
if ((Ccol == hg->ccolor) && (Ali == hg->cab) && (Csha == hg->cshade) && (Csty == hg->cstyle))
{
if (hg->ch == QChar(30))
960,6 → 976,8
hg->cshadowx = currItem->TxtShadowX;
hg->cshadowy = currItem->TxtShadowY;
hg->coutline = currItem->TxtOutline;
hg->cunderpos = currItem->TxtUnderPos;
hg->cunderwidth = currItem->TxtUnderWidth;
hg->cstyle = currItem->TxTStyle;
hg->cab = currItem->textAlignment;
hg->cextra = 0;
1110,6 → 1128,7
7 = Character Scaling Vertical
8 = Character Shadow
9 = Character Outline
10 = Character Underline
*/
void SEditor::updateSel(int code, struct PtiSmall *hg)
{
1170,6 → 1189,10
case 9:
chars->at(ca)->coutline = hg->coutline;
break;
case 10:
chars->at(ca)->cunderpos = hg->cunderpos;
chars->at(ca)->cunderwidth = hg->cunderwidth;
break;
default:
break;
}
1487,8 → 1510,17
connect(SeStyle->ShadowVal->Xoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowHandler()));
connect(SeStyle->ShadowVal->Yoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowHandler()));
connect(SeStyle->OutlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newOutlineHandler()));
connect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
connect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
}
 
void SToolBStyle::newUnderlineHandler()
{
int x = qRound(SeStyle->UnderlineVal->LPos->value() * 10.0);
int y = qRound(SeStyle->UnderlineVal->LWidth->value() * 10.0);
emit newUnderline(x, y);
}
 
void SToolBStyle::newOutlineHandler()
{
int x = qRound(SeStyle->OutlineVal->LWidth->value() * 10.0);
1514,6 → 1546,16
connect(SeStyle->OutlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newOutlineHandler()));
}
 
void SToolBStyle::setUnderline(int p, int w)
{
disconnect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
disconnect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
SeStyle->UnderlineVal->LWidth->setValue(w / 10.0);
SeStyle->UnderlineVal->LPos->setValue(p / 10.0);
connect(SeStyle->UnderlineVal->LWidth, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
connect(SeStyle->UnderlineVal->LPos, SIGNAL(valueChanged(int)), this, SLOT(newUnderlineHandler()));
}
 
void SToolBStyle::SetShadow(int x, int y)
{
disconnect(SeStyle->ShadowVal->Xoffset, SIGNAL(valueChanged(int)), this, SLOT(newShadowHandler()));
1831,6 → 1873,7
connect(StyleTools, SIGNAL(newStyle(int )), this, SLOT(newTxStyle(int )));
connect(StyleTools, SIGNAL(NewShadow(int, int)), this, SLOT(newShadowOffs(int, int)));
connect(StyleTools, SIGNAL(newOutline(int )), this, SLOT(newTxtOutline(int )));
connect(StyleTools, SIGNAL(newUnderline(int )), this, SLOT(newTxtUnderline(int, int)));
Editor->setFocus();
}
 
2045,6 → 2088,18
Editor->setFocus();
}
 
void StoryEditor::newTxtUnderline(int p, int w)
{
struct PtiSmall hg;
hg.cunderpos = p;
hg.cunderwidth = w;
Editor->CurrTextUnderPos = p;
Editor->CurrTextUnderWidth = w;
Editor->updateSel(10, &hg);
modifiedText();
Editor->setFocus();
}
 
void StoryEditor::updateProps(int p, int ch)
{
ColorList::Iterator it;
2072,6 → 2127,8
Editor->CurrTextShadowX = CurrItem->TxtShadowX;
Editor->CurrTextShadowY = CurrItem->TxtShadowY;
Editor->CurrTextOutline = CurrItem->TxtOutline;
Editor->CurrTextUnderPos = CurrItem->TxtUnderPos;
Editor->CurrTextUnderWidth = CurrItem->TxtUnderWidth;
c = 0;
StrokeTools->SetShade(CurrItem->ShTxtStroke);
FillTools->SetShade(CurrItem->ShTxtFill);
2105,6 → 2162,7
StyleTools->SetStyle(CurrItem->TxTStyle);
StyleTools->SetShadow(CurrItem->TxtShadowX, CurrItem->TxtShadowY);
StyleTools->setOutline(CurrItem->TxtOutline);
StyleTools->setUnderline(CurrItem->TxtUnderPos, CurrItem->TxtUnderWidth);
FontTools->SetSize(CurrItem->ISize);
FontTools->SetFont(CurrItem->IFont);
FontTools->SetScale(CurrItem->TxtScale);
2171,6 → 2229,8
Editor->CurrTextShadowX = hg->cshadowx;
Editor->CurrTextShadowY = hg->cshadowy;
Editor->CurrTextOutline = hg->coutline;
Editor->CurrTextUnderPos = hg->cunderpos;
Editor->CurrTextUnderWidth = hg->cunderwidth;
}
StrokeTools->SetShade(Editor->CurrTextStrokeSh);
FillTools->SetShade(Editor->CurrTextFillSh);
2213,6 → 2273,7
StyleTools->SetStyle(Editor->CurrentStyle);
StyleTools->SetShadow(Editor->CurrTextShadowX, Editor->CurrTextShadowY);
StyleTools->setOutline(Editor->CurrTextOutline);
StyleTools->setUnderline(Editor->CurrTextUnderPos, Editor->CurrTextUnderWidth);
FontTools->SetSize(Editor->CurrFontSize);
FontTools->SetFont(Editor->CurrFont);
FontTools->SetScale(Editor->CurrTextScale);
2579,6 → 2640,12
Editor->CurrTextKern = CurrItem->ExtraV;
Editor->CurrTextScale = CurrItem->TxtScale;
Editor->CurrTextScaleV = CurrItem->TxtScaleV;
Editor->CurrTextBase = CurrItem->TxtBase;
Editor->CurrTextShadowX = CurrItem->TxtShadowX;
Editor->CurrTextShadowY = CurrItem->TxtShadowY;
Editor->CurrTextOutline = CurrItem->TxtOutline;
Editor->CurrTextUnderPos = CurrItem->TxtUnderPos;
Editor->CurrTextUnderWidth = CurrItem->TxtUnderWidth;
}
Editor->setStyle(Editor->CurrentStyle);
if (Editor->CurrentStyle & 4)
2697,6 → 2764,12
Editor->CurrTextKern = CurrItem->ExtraV;
Editor->CurrTextScale = CurrItem->TxtScale;
Editor->CurrTextScaleV = CurrItem->TxtScaleV;
Editor->CurrTextBase = CurrItem->TxtBase;
Editor->CurrTextShadowX = CurrItem->TxtShadowX;
Editor->CurrTextShadowY = CurrItem->TxtShadowY;
Editor->CurrTextOutline = CurrItem->TxtOutline;
Editor->CurrTextUnderPos = CurrItem->TxtUnderPos;
Editor->CurrTextUnderWidth = CurrItem->TxtUnderWidth;
}
Editor->setStyle(Editor->CurrentStyle);
if (Editor->CurrentStyle & 4)
/branches/Version13x/Scribus/scribus/icons/wordsOnly.png
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
/branches/Version13x/Scribus/scribus/icons/Unter.xpm
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
/branches/Version13x/Scribus/scribus/pageitem.h
131,6 → 131,8
int shadowY;
int outline;
int base;
int underpos;
int underwidth;
bool Sele;
QString Zeich;
QString Farb;
203,6 → 205,8
int TxtShadowX;
int TxtShadowY;
int TxtOutline;
int TxtUnderPos;
int TxtUnderWidth;
int Cols;
double ColGap;
/** Strichstaerke */
/branches/Version13x/Scribus/scribus/styleselect.h
8,6 → 8,25
class QLabel;
class QPopupMenu;
 
class UnderlineValues : public QGroupBox
{
Q_OBJECT
 
public:
UnderlineValues( QWidget* parent );
~UnderlineValues() {};
MSpinBox* LPos;
MSpinBox* LWidth;
QLabel* LPosTxt;
QLabel* LWidthTxt;
 
public slots:
void languageChange();
protected:
QGridLayout* group1Layout;
};
 
class OutlineValues : public QGroupBox
{
Q_OBJECT
56,6 → 75,7
int getStyle();
ShadowValues* ShadowVal;
OutlineValues* OutlineVal;
UnderlineValues* UnderlineVal;
 
public slots:
void languageChange();
85,6 → 105,7
QToolButton* shadowButton;
QPopupMenu* ShadowPop;
QPopupMenu* OutlinePop;
QPopupMenu* UnderlinePop;
};
 
#endif
/branches/Version13x/Scribus/scribus/scribusstructs.h
52,6 → 52,8
short cshadowx;
short cshadowy;
short coutline;
short cunderpos;
short cunderwidth;
float cextra;
float xp;
float yp;
100,6 → 102,8
int TxtShadowX;
int TxtShadowY;
int TxtOutline;
int TxtUnderPos;
int TxtUnderWidth;
double Rot;
int PLineArt;
int PLineJoin;
/branches/Version13x/Scribus/scribus/pageitem.cpp
110,6 → 110,8
TxtOutline = 10;
TxTStyle = 0;
TxtBase = 0;
TxtUnderWidth = Doc->typographicSetttings.valueUnderlineWidth;
TxtUnderPos = Doc->typographicSetttings.valueUnderlinePos;
GrType = 0;
GrStartX = 0;
GrStartY = 0;
704,6 → 706,8
Zli3.shadowY = hl->cshadowy;
Zli3.outline = hl->coutline;
Zli3.base = hl->cbase;
Zli3.underpos = hl->cunderpos;
Zli3.underwidth = hl->cunderwidth;
for (int cx = 0; cx < coun; ++cx)
{
Zli3.xco = sPos + wt * cx;
734,6 → 738,8
Zli3.shadowX = hl->cshadowx;
Zli3.shadowY = hl->cshadowy;
Zli3.outline = hl->coutline;
Zli3.underpos = hl->cunderpos;
Zli3.underwidth = hl->cunderwidth;
if (!Doc->RePos)
{
desc = Zli3.ZFo->numDescender * (-Zli3.Siz / 10.0);
1317,6 → 1323,8
Zli->shadowX = hl->cshadowx;
Zli->shadowY = hl->cshadowy;
Zli->outline = hl->coutline;
Zli->underpos = hl->cunderpos;
Zli->underwidth = hl->cunderwidth;
if (((hl->ch == " ") || (hl->ch == QChar(9))) && (!outs))
{
if (a > 0)
1430,6 → 1438,8
Zli->shadowX = itemText.at(a)->cshadowx;
Zli->shadowY = itemText.at(a)->cshadowy;
Zli->outline = itemText.at(a)->coutline;
Zli->underpos = itemText.at(a)->cunderpos;
Zli->underwidth = itemText.at(a)->cunderwidth;
LiList.insert(LastSP+1, Zli);
LastSP += 1;
}
1700,6 → 1710,8
Zli->shadowX = Zli2->shadowX;
Zli->shadowY = Zli2->shadowY;
Zli->outline = Zli2->outline;
Zli->underpos = Zli2->underpos;
Zli->underwidth = Zli2->underwidth;
for (int cx = 0; cx < coun; ++cx)
{
Zli->xco = sPos + wt * cx;
1835,6 → 1847,8
Zli->shadowX = Zli2->shadowX;
Zli->shadowY = Zli2->shadowY;
Zli->outline = Zli2->outline;
Zli->underpos = Zli2->underpos;
Zli->underwidth = Zli2->underwidth;
for (int cx = 0; cx < coun; ++cx)
{
Zli->xco = sPos + wt * cx;
2282,6 → 2296,8
Zli->shadowX = hl->cshadowx;
Zli->shadowY = hl->cshadowx;
Zli->outline = hl->coutline;
Zli->underpos = hl->cunderpos;
Zli->underwidth = hl->cunderwidth;
if (!Doc->RePos)
DrawZeichenS(p, Zli);
delete Zli;
2590,14 → 2606,14
if ((hl->Style & 8) || ((hl->Style & 512) && (!ccx[0].isSpace())))
{
double st, lw;
if ((Doc->typographicSetttings.valueUnderlinePos != -1) || (Doc->typographicSetttings.valueUnderlineWidth != -1))
if ((hl->underpos != -1) || (hl->underwidth != -1))
{
if (Doc->typographicSetttings.valueUnderlinePos != -1)
st = (Doc->typographicSetttings.valueUnderlinePos / 100.0) * (hl->ZFo->numDescender * (hl->realSiz / 10.0));
if (hl->underpos != -1)
st = (hl->underpos / 1000.0) * (hl->ZFo->numDescender * (hl->realSiz / 10.0));
else
st = hl->ZFo->underline_pos * (hl->realSiz / 10.0);
if (Doc->typographicSetttings.valueUnderlineWidth != -1)
lw = (Doc->typographicSetttings.valueUnderlineWidth / 100.0) * (hl->realSiz / 10.0);
if (hl->underwidth != -1)
lw = (hl->underwidth / 1000.0) * (hl->realSiz / 10.0);
else
lw = QMAX(hl->ZFo->strokeWidth * (hl->realSiz / 10.0), 1);
}
/branches/Version13x/Scribus/scribus/tabtypography.cpp
79,9 → 79,7
textLabel1 = new QLabel( underlineGroup, "textLabel1" );
textLabel1->setText( tr( "Displacement:" ) );
underlineGroupLayout->addWidget( textLabel1, 0, 0 );
underlinePos = new QSpinBox( underlineGroup, "underlinePos" );
underlinePos->setMaxValue( 100 );
underlinePos->setMinValue( -1 );
underlinePos = new MSpinBox( -0.1, 100, underlineGroup, 1 );
underlinePos->setWrapping(true);
underlinePos->setSuffix( tr( " %" ) );
underlinePos->setSpecialValueText( tr( "Auto" ) );
89,9 → 87,7
textLabel2 = new QLabel( underlineGroup, "textLabel2" );
textLabel2->setText( tr( "Line Width:" ) );
underlineGroupLayout->addWidget( textLabel2, 0, 2 );
underlineWidth = new QSpinBox( underlineGroup, "underlineWidth" );
underlineWidth->setMaxValue( 100 );
underlineWidth->setMinValue( -1 );
underlineWidth = new MSpinBox( -0.1, 100, underlineGroup, 1 );
underlineWidth->setSuffix( tr( " %" ) );
underlineWidth->setWrapping(true);
underlineWidth->setSpecialValueText( tr( "Auto" ) );
/branches/Version13x/Scribus/scribus/scribusdoc.h
177,6 → 177,8
int CurrTextShadowX;
int CurrTextShadowY;
int CurrTextOutline;
int CurrTextUnderPos;
int CurrTextUnderWidth;
bool EditClip;
int EditClipMode;
typoPrefs typographicSetttings;
/branches/Version13x/Scribus/scribus/scribusview.cpp
2422,6 → 2422,9
Doc->CurrTextShadowX = currItem->TxtShadowX;
Doc->CurrTextShadowY = currItem->TxtShadowY;
Doc->CurrTextOutline = currItem->TxtOutline;
Doc->CurrTextUnderPos = currItem->TxtUnderPos;
Doc->CurrTextUnderWidth = currItem->TxtUnderWidth;
emit ItemTextUnderline(currItem->TxtUnderPos, currItem->TxtUnderWidth);
emit ItemTextOutline(currItem->TxtOutline);
emit ItemTextShadow(currItem->TxtShadowX, currItem->TxtShadowY);
emit ItemTextAttr(currItem->LineSp);
6487,6 → 6490,9
Doc->CurrTextShadowX = currItem->itemText.at(a)->cshadowx;
Doc->CurrTextShadowY = currItem->itemText.at(a)->cshadowy;
Doc->CurrTextOutline = currItem->itemText.at(a)->coutline;
Doc->CurrTextUnderPos = currItem->itemText.at(a)->cunderpos;
Doc->CurrTextUnderWidth = currItem->itemText.at(a)->cunderwidth;
emit ItemTextUnderline(currItem->itemText.at(a)->cunderpos, currItem->itemText.at(a)->cunderwidth);
emit ItemTextOutline(currItem->itemText.at(a)->coutline);
emit ItemTextShadow(currItem->itemText.at(a)->cshadowx, currItem->itemText.at(a)->cshadowy);
emit ItemTextBase(currItem->itemText.at(a)->cbase);
6527,6 → 6533,9
Doc->CurrTextShadowX = currItem->itemText.at(i)->cshadowx;
Doc->CurrTextShadowY = currItem->itemText.at(i)->cshadowy;
Doc->CurrTextOutline = currItem->itemText.at(i)->coutline;
Doc->CurrTextUnderPos = currItem->itemText.at(i)->cunderpos;
Doc->CurrTextUnderWidth = currItem->itemText.at(i)->cunderwidth;
emit ItemTextUnderline(currItem->itemText.at(i)->cunderpos, currItem->itemText.at(i)->cunderwidth);
emit ItemTextOutline(currItem->itemText.at(i)->coutline);
emit ItemTextShadow(currItem->itemText.at(i)->cshadowx, currItem->itemText.at(i)->cshadowy);
emit ItemTextSca(currItem->itemText.at(i)->cscale);
6556,6 → 6565,9
Doc->CurrTextShadowX = currItem->itemText.at(currItem->CPos-1)->cshadowx;
Doc->CurrTextShadowY = currItem->itemText.at(currItem->CPos-1)->cshadowy;
Doc->CurrTextOutline = currItem->itemText.at(currItem->CPos-1)->coutline;
Doc->CurrTextUnderPos = currItem->itemText.at(currItem->CPos-1)->cunderpos;
Doc->CurrTextUnderWidth = currItem->itemText.at(currItem->CPos-1)->cunderwidth;
emit ItemTextUnderline(currItem->itemText.at(currItem->CPos-1)->cunderpos, currItem->itemText.at(currItem->CPos-1)->cunderwidth);
emit ItemTextOutline(currItem->itemText.at(currItem->CPos-1)->coutline);
emit ItemTextShadow(currItem->itemText.at(currItem->CPos-1)->cshadowx, currItem->itemText.at(currItem->CPos-1)->cshadowy);
emit ItemTextSca(currItem->itemText.at(currItem->CPos-1)->cscale);
6584,6 → 6596,9
Doc->CurrTextShadowX = currItem->TxtShadowX;
Doc->CurrTextShadowY = currItem->TxtShadowY;
Doc->CurrTextOutline = currItem->TxtOutline;
Doc->CurrTextUnderPos = currItem->TxtUnderPos;
Doc->CurrTextUnderWidth = currItem->TxtUnderWidth;
emit ItemTextUnderline(currItem->TxtUnderPos, currItem->TxtUnderWidth);
emit ItemTextOutline(currItem->TxtOutline);
emit ItemTextShadow(currItem->TxtShadowX, currItem->TxtShadowY);
emit ItemTextSca(currItem->TxtScale);
10013,6 → 10028,43
}
}
 
void ScribusView::setItemTextUnderline(int pos, int wid)
{
if (SelItem.count() != 0)
{
PageItem *currItem;
for (uint a = 0; a < SelItem.count(); ++a)
{
currItem = SelItem.at(a);
if ((currItem->itemType() == PageItem::TextFrame) || (currItem->itemType() == PageItem::PathText))
{
if (Doc->appMode != EditMode)
{
currItem->TxtUnderPos = pos;
currItem->TxtUnderWidth = wid;
}
for (uint i=0; i<currItem->itemText.count(); ++i)
{
if (Doc->appMode == EditMode)
{
if (currItem->itemText.at(i)->cselect)
{
currItem->itemText.at(i)->cunderpos = pos;
currItem->itemText.at(i)->cunderwidth = wid;
}
}
else
{
currItem->itemText.at(i)->cunderpos = pos;
currItem->itemText.at(i)->cunderwidth = wid;
}
}
}
RefreshItem(currItem);
}
}
}
 
void ScribusView::setItemTextBase(int sha)
{
if (SelItem.count() != 0)
10957,6 → 11009,10
hg->cshadowy = it == NULL ? -50 : (*it).toInt();
it++;
hg->coutline = it == NULL ? 10 : (*it).toInt();
it++;
hg->cunderpos = it == NULL ? -1 : (*it).toInt();
it++;
hg->cunderwidth = it == NULL ? -1 : (*it).toInt();
hg->xp = 0;
hg->yp = 0;
hg->PRot = 0;
10998,6 → 11054,8
currItem->TxtShadowX = Buffer->TxtShadowX;
currItem->TxtShadowY = Buffer->TxtShadowY;
currItem->TxtOutline = Buffer->TxtOutline;
currItem->TxtUnderPos = Buffer->TxtUnderPos;
currItem->TxtUnderWidth = Buffer->TxtUnderWidth;
currItem->Rot = Buffer->Rot;
currItem->Extra = Buffer->Extra;
currItem->TExtra = Buffer->TExtra;
/branches/Version13x/Scribus/scribus/libpostscript/pslib.cpp
2007,6 → 2007,8
hl2.cshadowx = hl->cshadowx;
hl2.cshadowy = hl->cshadowy;
hl2.coutline = hl->coutline;
hl2.cunderpos = hl->cunderpos;
hl2.cunderwidth = hl->cunderwidth;
for (int cx = 0; cx < coun; ++cx)
{
hl2.xp = sPos + wt * cx;
2028,6 → 2030,8
hl3.cextra = hl2.cextra;
hl3.cbase = hl2.cbase;
hl3.coutline = hl2.coutline;
hl3.cunderpos = hl2.cunderpos;
hl3.cunderwidth = hl2.cunderwidth;
setTextCh(Doc, ite, gcr, a, d, &hl3);
}
setTextCh(Doc, ite, gcr, a, d, &hl2);
2057,6 → 2061,8
hl2.cshadowx = hl->cshadowx;
hl2.cshadowy = hl->cshadowy;
hl2.coutline = hl->coutline;
hl2.cunderpos = hl->cunderpos;
hl2.cunderwidth = hl->cunderwidth;
setTextCh(Doc, ite, gcr, a, d, &hl2);
}
setTextCh(Doc, ite, gcr, a, d, hl);
2292,14 → 2298,14
kern = 0;
else
kern = hl->cextra;
if ((Doc->typographicSetttings.valueUnderlinePos != -1) || (Doc->typographicSetttings.valueUnderlineWidth != -1))
if ((hl->cunderpos != -1) || (hl->cunderwidth != -1))
{
if (Doc->typographicSetttings.valueUnderlinePos != -1)
Upos = (Doc->typographicSetttings.valueUnderlinePos / 100.0) * (hl->cfont->numDescender * (hl->csize / 10.0));
if (hl->cunderpos != -1)
Upos = (hl->cunderpos / 1000.0) * (hl->cfont->numDescender * (hl->csize / 10.0));
else
Upos = hl->cfont->underline_pos * (hl->csize / 10.0);
if (Doc->typographicSetttings.valueUnderlineWidth != -1)
lw = (Doc->typographicSetttings.valueUnderlineWidth / 100.0) * (hl->csize / 10.0);
if (hl->cunderwidth != -1)
lw = (hl->cunderwidth / 1000.0) * (hl->csize / 10.0);
else
lw = QMAX(hl->cfont->strokeWidth * (hl->csize / 10.0), 1);
}
/branches/Version13x/Scribus/scribus/scribus.cpp
294,6 → 294,7
connect(this, SIGNAL(TextBase(int)), propertiesPalette, SLOT(setTBase(int)));
connect(this, SIGNAL(TextShadow(int, int )), propertiesPalette, SLOT(setShadowOffs(int, int )));
connect(this, SIGNAL(TextOutline(int)), propertiesPalette, SLOT(setOutlineW(int)));
connect(this, SIGNAL(TextUnderline(int, int)), propertiesPalette, SLOT(setUnderline(int, int)));
connect(this, SIGNAL(TextFarben(QString, QString, int, int)), propertiesPalette, SLOT(setActFarben(QString, QString, int, int)));
 
initCrashHandler();
1448,6 → 1449,9
doc->CurrTextShadowX = currItem->itemText.at(ChPos)->cshadowx;
doc->CurrTextShadowY = currItem->itemText.at(ChPos)->cshadowy;
doc->CurrTextOutline = currItem->itemText.at(ChPos)->coutline;
doc->CurrTextUnderPos = currItem->itemText.at(ChPos)->cunderpos;
doc->CurrTextUnderWidth = currItem->itemText.at(ChPos)->cunderwidth;
emit TextUnderline(doc->CurrTextUnderPos, doc->CurrTextUnderWidth);
emit TextShadow(doc->CurrTextShadowX, doc->CurrTextShadowY);
emit TextFarben(doc->CurrTextStroke, doc->CurrTextFill, doc->CurrTextStrokeSh, doc->CurrTextFillSh);
emit TextIFont(doc->CurrFont);
1510,6 → 1514,8
hg->cshadowx = doc->CurrTextShadowX;
hg->cshadowy = doc->CurrTextShadowY;
hg->coutline = doc->CurrTextOutline;
hg->cunderpos = doc->CurrTextUnderPos;
hg->cunderwidth = doc->CurrTextUnderWidth;
hg->cselect = false;
hg->cstyle = doc->CurrentStyle;
hg->cab = doc->currentParaStyle;
1953,6 → 1959,8
hg->cshadowx = doc->CurrTextShadowX;
hg->cshadowy = doc->CurrTextShadowY;
hg->coutline = doc->CurrTextOutline;
hg->cunderpos = doc->CurrTextUnderPos;
hg->cunderwidth = doc->CurrTextUnderWidth;
hg->cselect = false;
hg->cstyle = doc->CurrentStyle;
hg->cab = doc->currentParaStyle;
2393,6 → 2401,8
hg->cshadowx = doc->CurrTextShadowX;
hg->cshadowy = doc->CurrTextShadowY;
hg->coutline = doc->CurrTextOutline;
hg->cunderpos = doc->CurrTextUnderPos;
hg->cunderwidth = doc->CurrTextUnderWidth;
hg->cselect = false;
hg->cstyle = doc->CurrentStyle;
hg->cab = doc->currentParaStyle;
2429,6 → 2439,8
hg->cshadowx = doc->CurrTextShadowX;
hg->cshadowy = doc->CurrTextShadowY;
hg->coutline = doc->CurrTextOutline;
hg->cunderpos = doc->CurrTextUnderPos;
hg->cunderwidth = doc->CurrTextUnderWidth;
hg->cextra = 0;
hg->cselect = false;
hg->cstyle = doc->CurrentStyle;
3017,8 → 3029,8
doc->typographicSetttings.autoLineSpacing = dia->tabTypo->autoLine->value();
doc->typographicSetttings.valueBaseGrid = dia->tabGuides->baseGrid->value() / doc->unitRatio;
doc->typographicSetttings.offsetBaseGrid = dia->tabGuides->baseOffset->value() / doc->unitRatio;
doc->typographicSetttings.valueUnderlinePos = dia->tabTypo->underlinePos->value();
doc->typographicSetttings.valueUnderlineWidth = dia->tabTypo->underlineWidth->value();
doc->typographicSetttings.valueUnderlinePos = qRound(dia->tabTypo->underlinePos->value() * 10);
doc->typographicSetttings.valueUnderlineWidth = qRound(dia->tabTypo->underlineWidth->value() * 10);
doc->typographicSetttings.valueStrikeThruPos = dia->tabTypo->strikethruPos->value();
doc->typographicSetttings.valueStrikeThruWidth = dia->tabTypo->strikethruWidth->value();
doc->toolSettings.defFont = dia->tabTools->fontComboText->currentText();
3558,6 → 3570,7
connect(view, SIGNAL(ItemTextScaV(int)), propertiesPalette, SLOT(setTScaleV(int)));
connect(view, SIGNAL(ItemTextBase(int)), propertiesPalette, SLOT(setTBase(int)));
connect(view, SIGNAL(ItemTextShadow(int, int )), propertiesPalette, SLOT(setShadowOffs(int, int )));
connect(view, SIGNAL(ItemTextUnderline(int, int)), propertiesPalette, SLOT(setUnderline(int, int)));
connect(view, SIGNAL(ItemTextOutline(int)), propertiesPalette, SLOT(setOutlineW(int)));
connect(view, SIGNAL(ItemTextSize(int)), this, SLOT(setFSizeMenu(int)));
connect(view, SIGNAL(ItemTextStil(int)), this, SLOT(setStilvalue(int)));
3795,6 → 3808,9
doc->CurrTextShadowX = currItem->TxtShadowX;
doc->CurrTextShadowY = currItem->TxtShadowY;
doc->CurrTextOutline = currItem->TxtOutline;
doc->CurrTextUnderPos = currItem->TxtUnderPos;
doc->CurrTextUnderWidth = currItem->TxtUnderWidth;
emit TextUnderline(doc->CurrTextUnderPos, doc->CurrTextUnderWidth);
emit TextShadow(doc->CurrTextShadowX, doc->CurrTextShadowY);
emit TextFarben(doc->CurrTextStroke, doc->CurrTextFill, doc->CurrTextStrokeSh, doc->CurrTextFillSh);
doc->CurrentStyle = currItem->TxTStyle;
3858,6 → 3874,9
doc->CurrTextShadowX = currItem->TxtShadowX;
doc->CurrTextShadowY = currItem->TxtShadowY;
doc->CurrTextOutline = currItem->TxtOutline;
doc->CurrTextUnderPos = currItem->TxtUnderPos;
doc->CurrTextUnderWidth = currItem->TxtUnderWidth;
emit TextUnderline(doc->CurrTextUnderPos, doc->CurrTextUnderWidth);
emit TextShadow(doc->CurrTextShadowX, doc->CurrTextShadowY);
emit TextFarben(doc->CurrTextStroke, doc->CurrTextFill, doc->CurrTextStrokeSh, doc->CurrTextFillSh);
doc->CurrentStyle = currItem->TxTStyle;
5369,7 → 5388,9
Buffer2 += QString::number(currItem->itemText.at(a)->cbase)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cshadowx)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cshadowy)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->coutline)+'\n';
Buffer2 += QString::number(currItem->itemText.at(a)->coutline)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cunderpos)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cunderwidth)+'\n';
}
}
deleteSelectedTextFromFrame(nextItem);
5451,7 → 5472,9
Buffer2 += QString::number(currItem->itemText.at(a)->cbase)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cshadowx)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cshadowy)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->coutline)+'\n';
Buffer2 += QString::number(currItem->itemText.at(a)->coutline)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cunderpos)+'\t';
Buffer2 += QString::number(currItem->itemText.at(a)->cunderwidth)+'\n';
}
}
nextItem = nextItem->NextBox;
5546,6 → 5569,10
hg->cshadowy = it == NULL ? -50 : (*it).toInt();
it++;
hg->coutline = it == NULL ? 10 : (*it).toInt();
it++;
hg->cunderpos = it == NULL ? -1 : (*it).toInt();
it++;
hg->cunderwidth = it == NULL ? -1 : (*it).toInt();
currItem->itemText.insert(currItem->CPos, hg);
currItem->CPos += 1;
hg->PRot = 0;
7919,8 → 7946,8
Prefs.typographicSetttings.autoLineSpacing = dia->tabTypo->autoLine->value();
Prefs.typographicSetttings.valueBaseGrid = dia->tabGuides->baseGrid->value() / UmReFaktor;
Prefs.typographicSetttings.offsetBaseGrid = dia->tabGuides->baseOffset->value() / UmReFaktor;
Prefs.typographicSetttings.valueUnderlinePos = dia->tabTypo->underlinePos->value();
Prefs.typographicSetttings.valueUnderlineWidth = dia->tabTypo->underlineWidth->value();
Prefs.typographicSetttings.valueUnderlinePos = qRound(dia->tabTypo->underlinePos->value() * 10);
Prefs.typographicSetttings.valueUnderlineWidth = qRound(dia->tabTypo->underlineWidth->value() * 10);
Prefs.typographicSetttings.valueStrikeThruPos = dia->tabTypo->strikethruPos->value();
Prefs.typographicSetttings.valueStrikeThruWidth = dia->tabTypo->strikethruWidth->value();
Prefs.toolSettings.dPen = dia->tabTools->colorComboLineShape->currentText();
/branches/Version13x/Scribus/scribus/plugins/scriptplugin/cmdtext.cpp
280,6 → 280,8
hg->cshadowx = currItem->TxtShadowX;
hg->cshadowy = currItem->TxtShadowY;
hg->coutline = currItem->TxtOutline;
hg->cunderpos = currItem->TxtUnderPos;
hg->cunderwidth = currItem->TxtUnderWidth;
hg->cextra = 0;
hg->cselect = false;
hg->cstyle = 0;
339,6 → 341,8
hg->cshadowx = it->TxtShadowX;
hg->cshadowy = it->TxtShadowY;
hg->coutline = it->TxtOutline;
hg->cunderpos = it->TxtUnderPos;
hg->cunderwidth = it->TxtUnderWidth;
hg->cextra = 0;
hg->cselect = false;
hg->cstyle = 0;
/branches/Version13x/Scribus/scribus/plugins/svgimplugin/svgplugin.cpp
1954,6 → 1954,8
ite->TxtShadowX = 50;
ite->TxtShadowY = -50;
ite->TxtOutline = 10;
ite->TxtUnderPos = -1;
ite->TxtUnderWidth = -1;
for (uint tt = 0; tt < Text.length(); ++tt)
{
hg = new ScText;
1971,6 → 1973,8
hg->cshadowx = 50;
hg->cshadowy = -50;
hg->coutline = 10;
hg->cunderpos = -1;
hg->cunderwidth = -1;
hg->cselect = false;
if( !tspan.attribute( "stroke" ).isEmpty() )
hg->cstyle = 4;
2045,6 → 2049,8
ite->TxtShadowX = 50;
ite->TxtShadowY = -50;
ite->TxtOutline = 10;
ite->TxtUnderPos = -1;
ite->TxtUnderWidth = -1;
for (uint cc = 0; cc<Text.length(); ++cc)
{
hg = new ScText;
2062,6 → 2068,8
hg->cshadowx = 50;
hg->cshadowy = -50;
hg->coutline = 10;
hg->cunderpos = -1;
hg->cunderwidth = -1;
hg->cselect = false;
if( !e.attribute( "stroke" ).isEmpty() )
hg->cstyle = 4;
/branches/Version13x/Scribus/scribus/libpdf/pdflib.cpp
2588,6 → 2588,8
hl2.cshadowx = hl->cshadowx;
hl2.cshadowy = hl->cshadowy;
hl2.coutline = hl->coutline;
hl2.cunderpos = hl->cunderpos;
hl2.cunderwidth = hl->cunderwidth;
for (int cx = 0; cx < coun; ++cx)
{
hl2.xp = sPos + wt * cx;
2609,6 → 2611,8
hl3.cextra = hl2.cextra;
hl3.cbase = hl2.cbase;
hl3.coutline = hl2.coutline;
hl3.cunderpos = hl2.cunderpos;
hl3.cunderwidth = hl2.cunderwidth;
setTextCh(ite, PNr, d, tmp, tmp2, &hl3);
}
setTextCh(ite, PNr, d, tmp, tmp2, &hl2);
2638,6 → 2642,8
hl2.cshadowx = hl->cshadowx;
hl2.cshadowy = hl->cshadowy;
hl2.coutline = hl->coutline;
hl2.cunderpos = hl->cunderpos;
hl2.cunderwidth = hl->cunderwidth;
setTextCh(ite, PNr, d, tmp, tmp2, &hl2);
}
setTextCh(ite, PNr, d, tmp, tmp2, hl);
2923,14 → 2929,14
kern = 0;
else
kern = hl->cextra;
if ((doc->typographicSetttings.valueUnderlinePos != -1) || (doc->typographicSetttings.valueUnderlineWidth != -1))
if ((hl->cunderpos != -1) || (hl->cunderwidth != -1))
{
if (doc->typographicSetttings.valueUnderlinePos != -1)
Upos = (doc->typographicSetttings.valueUnderlinePos / 100.0) * (hl->cfont->numDescender * (hl->csize / 10.0));
if (hl->cunderpos != -1)
Upos = (hl->cunderpos / 1000.0) * (hl->cfont->numDescender * (hl->csize / 10.0));
else
Upos = hl->cfont->underline_pos * (hl->csize / 10.0);
if (doc->typographicSetttings.valueUnderlineWidth != -1)
Uwid = (doc->typographicSetttings.valueUnderlineWidth / 100.0) * (hl->csize / 10.0);
if (hl->cunderwidth != -1)
Uwid = (hl->cunderwidth / 1000.0) * (hl->csize / 10.0);
else
Uwid = QMAX(hl->cfont->strokeWidth * (hl->csize / 10.0), 1);
}
/branches/Version13x/Scribus/scribus/scribus.h
465,6 → 465,7
void TextBase(int);
void TextShadow(int, int);
void TextOutline(int);
void TextUnderline(int, int);
 
void prefsChanged();
 
/branches/Version13x/Scribus/scribus/story.h
54,6 → 54,8
short cshadowx;
short cshadowy;
short coutline;
short cunderpos;
short cunderwidth;
double cextra;
QString ch;
QString cfont;
101,6 → 103,8
int CurrTextShadowX;
int CurrTextShadowY;
int CurrTextOutline;
int CurrTextUnderPos;
int CurrTextUnderWidth;
double CurrTextKern;
QString CurrTextStroke;
QString CurrTextFill;
219,10 → 223,12
MSpinBox* Extra;
 
public slots:
void newUnderlineHandler();
void newOutlineHandler();
void newShadowHandler();
void newKernHandler();
void SetShadow(int x, int y);
void setUnderline(int p, int w);
void setOutline(int o);
void SetStyle(int s);
void SetKern(double k);
231,6 → 237,7
void NewKern(double);
void NewShadow(int, int);
void newOutline(int);
void newUnderline(int, int);
void newStyle(int);
};
 
356,6 → 363,7
void newTxKern(double s);
void newShadowOffs(int x, int y);
void newTxtOutline(int o);
void newTxtUnderline(int p, int w);
void updateProps(int p, int ch);
void newAlign(int st);
void changeAlignSB(int pa, int align);