Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 181 → Rev 182

/trunk/Scribus/ChangeLogCVS
1,4 → 1,8
Changes since Version 1.1.4
01.02.2004 The Rulers are now following the Magnification.
Some minor Code cleanups.
Added a Scribus.pro file for use with lupdate for creating Translations.
 
31.01.2004 Added a new Guide Manager from Allessandro Rimoldini.
More speedups for the Scripter.
 
/trunk/Scribus/Scribus.pro
0,0 → 1,133
######################################################################
# Automatically generated by qmake (1.04a) Fri Jan 30 19:52:25 2004
######################################################################
 
SOURCES += scribus/align.cpp \
scribus/alignselect.cpp \
scribus/annot.cpp \
scribus/annota.cpp \
scribus/applytemplate.cpp \
scribus/art_kmisc.c \
scribus/art_render_misc.c \
scribus/art_render_pattern.c \
scribus/art_rgb.c \
scribus/art_rgb_affine_private.c \
scribus/art_rgb_svp.c \
scribus/art_rgba_affine.c \
scribus/autoform.cpp \
scribus/bookmwin.cpp \
scribus/bookpalette.cpp \
scribus/buttonicon.cpp \
scribus/cmsprefs.cpp \
scribus/cmykcolor.cpp \
scribus/cmykfw.cpp \
scribus/colorchart.cpp \
scribus/colorm.cpp \
scribus/cpalette.cpp \
scribus/cupsoptions.cpp \
scribus/customfdialog.cpp \
scribus/dcolor.cpp \
scribus/delpages.cpp \
scribus/docinfo.cpp \
scribus/druck.cpp \
scribus/edit1format.cpp \
scribus/editformats.cpp \
scribus/editor.cpp \
scribus/fmitem.cpp \
scribus/fontcombo.cpp \
scribus/fontprefs.cpp \
scribus/fparser.cpp \
scribus/fpoint.cpp \
scribus/fpointarray.cpp \
scribus/frameedit.cpp \
scribus/gdk-pixbuf-xlib-drawable.c \
scribus/gdk-pixbuf-xlib-render.c \
scribus/gdk-pixbuf-xlib.c \
scribus/gdk-pixbuf-xlibrgb.c \
scribus/guidemanager.cpp \
scribus/helpbrowser.cpp \
scribus/hnjalloc.c \
scribus/hruler.cpp \
scribus/hyask.cpp \
scribus/hyphen.c \
scribus/hyphenator.cpp \
scribus/hysettings.cpp \
scribus/inspage.cpp \
scribus/javadocs.cpp \
scribus/keymanager.cpp \
scribus/layers.cpp \
scribus/linecombo.cpp \
scribus/lineformats.cpp \
scribus/linkbutton.cpp \
scribus/main.cpp \
scribus/md5.c \
scribus/mdup.cpp \
scribus/mergedoc.cpp \
scribus/missing.cpp \
scribus/movepage.cpp \
scribus/mpalette.cpp \
scribus/mspinbox.cpp \
scribus/multiline.cpp \
scribus/muster.cpp \
scribus/navigator.cpp \
scribus/newfile.cpp \
scribus/newtemp.cpp \
scribus/page.cpp \
scribus/pageback.cpp \
scribus/pageitem.cpp \
scribus/pdfopts.cpp \
scribus/picsearch.cpp \
scribus/picstatus.cpp \
scribus/polyprops.cpp \
scribus/query.cpp \
scribus/rc4.c \
scribus/reformdoc.cpp \
scribus/scfonts.cpp \
scribus/scfonts_ttf.cpp \
scribus/scpainter.cpp \
scribus/scpreview.cpp \
scribus/scrap.cpp \
scribus/scribus.cpp \
scribus/scribusdoc.cpp \
scribus/scribusview.cpp \
scribus/scribuswin.cpp \
scribus/scribusXml.cpp \
scribus/search.cpp \
scribus/seiten.cpp \
scribus/selfield.cpp \
scribus/serializer.cpp \
scribus/shadebutton.cpp \
scribus/spalette.cpp \
scribus/splash.cpp \
scribus/story.cpp \
scribus/styleselect.cpp \
scribus/tabmanager.cpp \
scribus/translationdummy.cpp \
scribus/tree.cpp \
scribus/util.cpp \
scribus/vgradient.cpp \
scribus/vruler.cpp \
scribus/werktoolb.cpp \
scribus/libabout/about.cpp \
scribus/libpdf/pdflib.cpp \
scribus/libpostscript/pslib.cpp \
scribus/libprefs/prefs.cpp \
scribus/plugins/libchar/charselect.cpp \
scribus/plugins/printpreview/preview.cpp \
scribus/plugins/scriptplugin/cmdcolor.cpp \
scribus/plugins/scriptplugin/cmddialog.cpp \
scribus/plugins/scriptplugin/cmddoc.cpp \
scribus/plugins/scriptplugin/cmdgetprop.cpp \
scribus/plugins/scriptplugin/cmdmani.cpp \
scribus/plugins/scriptplugin/cmdmisc.cpp \
scribus/plugins/scriptplugin/cmdobj.cpp \
scribus/plugins/scriptplugin/cmdpage.cpp \
scribus/plugins/scriptplugin/cmdsetprop.cpp \
scribus/plugins/scriptplugin/cmdtext.cpp \
scribus/plugins/scriptplugin/cmdutil.cpp \
scribus/plugins/scriptplugin/conswin.cpp \
scribus/plugins/scriptplugin/pconsole.cpp \
scribus/plugins/scriptplugin/scriptplugin.cpp \
scribus/plugins/svgexplugin/svgexplugin.cpp \
scribus/plugins/svgimplugin/svgplugin.cpp
TRANSLATIONS += scribus.ts
Property changes:
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: svn:keywords
## -0,0 +1 ##
+Author Date Id Revision
\ No newline at end of property
Index: Scribus/scribus/mpalette.cpp
===================================================================
--- Scribus/scribus/mpalette.cpp (revision 181)
+++ Scribus/scribus/mpalette.cpp (revision 182)
@@ -855,25 +855,25 @@
DLeft->setDecimals(10);
DBottom->setDecimals(10);
DRight->setDecimals(10);
- Xpos->setMaxValue( 3000 );
+ Xpos->setMaxValue( doc->PageB );
Xpos->setMinValue( -3000 );
- Ypos->setMaxValue( 3000 );
+ Ypos->setMaxValue( doc->PageH );
Ypos->setMinValue( -3000 );
- Width->setMaxValue( 3000 );
+ Width->setMaxValue( doc->PageB );
Width->setMinValue( 1 );
- Height->setMaxValue( 3000 );
+ Height->setMaxValue( doc->PageH );
Height->setMinValue( 1 );
- Rot->setMaxValue( 360 );
+ Rot->setMaxValue( 359 );
Rot->setMinValue( 0 );
RoundRect->setMaxValue( 300 );
RoundRect->setMinValue( -300);
- LYpos->setMaxValue( 3000 );
+ LYpos->setMaxValue( doc->PageB );
LYpos->setMinValue( -3000 );
ScaleY->setMaxValue( 3000 );
ScaleY->setMinValue( 1 );
ScaleX->setMaxValue( 3000 );
ScaleX->setMinValue( 1 );
- LXpos->setMaxValue( 3000 );
+ LXpos->setMaxValue( doc->PageH );
LXpos->setMinValue( -3000 );
Size->setMaxValue( 1024 );
Size->setMinValue( 1 );
@@ -1296,8 +1296,6 @@
double oldRR = RoundRect->value() / old;
double oldRM = RoundRect->maxValue() / old;
Umrech = UmReFaktor;
- Width->setLineStep(100);
- Height->setLineStep(100);
Xpos->setDecimals(100);
Ypos->setDecimals(100);
Width->setDecimals(100);
@@ -1361,6 +1359,14 @@
DBottom->setSuffix( ein );
DRight->setSuffix( ein );
RoundRect->setSuffix( ein );
+ Xpos->setMaxValue( doc->PageB );
+ Xpos->setMinValue( -3000 );
+ Ypos->setMaxValue( doc->PageH );
+ Ypos->setMinValue( -3000 );
+ Width->setMaxValue( doc->PageB );
+ Width->setMinValue( 1 );
+ Height->setMaxValue( doc->PageH );
+ Height->setMinValue( 1 );
Xpos->setValue(oldX * UmReFaktor);
Ypos->setValue(oldY * UmReFaktor);
Width->setValue(oldW * UmReFaktor);
Index: Scribus/scribus/translationdummy.cpp
===================================================================
--- Scribus/scribus/translationdummy.cpp (revision 181)
+++ Scribus/scribus/translationdummy.cpp (revision 182)
@@ -109,4 +109,21 @@
tr("%1 - [%2]");
tr("&Unshade");
}
+QColorDialog::QColorDialog()
+{
+tr("Hu&e:");
+tr("&Sat:");
+tr("&Val:");
+tr("&Red:");
+tr("&Green:");
+tr("Bl&ue:");
+tr("A&lpha channel:");
+tr("&Basic colors");
+tr("&Custom colors");
+tr("&Define Custom Colors >>");
+tr("OK");
+tr("Cancel");
+tr("&Add to Custom Colors");
+tr("Select color");
+}
/trunk/Scribus/scribus/vruler.cpp
57,25 → 57,60
int xx, pc;
double of, xl, iter, iter2;
double sc = doku->Scale;
int cor = 1;
if (sc > 1)
cor = 2;
if (sc > 4)
cor = 10;
switch (doku->Einheit)
{
{
case 0:
iter = 10.0;
iter2 = iter * 10.0;
if (sc > 1)
cor = 2;
if (sc > 4)
cor = 10;
iter = 10.0 / cor;
iter2 = iter * 10.0;
break;
case 1:
iter = (10.0 / 25.4) * 72.0;
iter2 = iter * 10.0;
if (sc > 1)
cor = 10;
iter = ((10.0 / 25.4) * 72.0) / cor;
iter2 = iter * 10.0;
break;
case 2:
iter = 18.0;
iter2 = 72.0;
if (sc > 1)
{
cor = 2;
iter = 9.0;
iter2 = 36.0;
}
if (sc > 4)
{
iter = 9.0;
iter2 = 18.0;
cor = 4;
}
break;
case 3:
iter = 12.0;
iter2 = 120.0;
if (sc > 1)
{
cor = 1;
iter = 12.0;
iter2 = 60.0;
}
if (sc > 4)
{
cor = 2;
iter = 6.0;
iter2 = 12.0;
}
break;
}
}
QPainter p;
p.begin(this);
p.drawLine(24, 0, 24, height());
83,53 → 118,47
p.setBrush(black);
p.setPen(black);
p.setFont(font());
p.scale(1.0, sc);
if ((doku->PageFP) && (doku->PagesSbS))
{
if (doku->FirstPageLeft)
{
if (doku->FirstPageLeft)
{
if (doku->PageC % 2 == 0)
pc = doku->PageC / 2;
else
pc = (doku->PageC+1) / 2;
}
}
else
{
{
if (doku->PageC % 2 == 0)
pc = doku->PageC / 2 + 1;
else
pc = doku->PageC / 2 + 1;
}
}
}
else
pc = doku->PageC;
for (xx = 0; xx < pc; ++xx)
{
{
of = xx * (doku->PageH+30.0);
for (xl = 0; xl < doku->PageH; xl += iter)
{
p.drawLine(18, static_cast<int>(xl+of), 24, static_cast<int>(xl+of));
}
p.drawLine(18, qRound((xl+of)*sc), 24, qRound((xl+of)*sc));
for (xl = 0; xl < doku->PageH+(iter2/2); xl += iter2)
{
p.drawLine(11, qRound((xl+of)*sc), 24, qRound((xl+of)*sc));
switch (doku->Einheit)
{
p.drawLine(11, static_cast<int>(xl+of), 24, static_cast<int>(xl+of));
p.save();
p.scale(1.0, 1.0 / sc);
switch (doku->Einheit)
{
case 2:
p.drawText(9, static_cast<int>((xl+of+qRound(10/sc)) * sc), QString::number(xl / iter2));
p.drawText(9, qRound((xl+of+10/sc) * sc), QString::number(xl / iter2 / cor));
break;
case 3:
p.drawText(9, static_cast<int>((xl+of+qRound(10/sc)) * sc), QString::number(xl / iter));
p.drawText(9, qRound((xl+of+10/sc) * sc), QString::number(xl / iter / cor));
break;
default:
p.drawText(9, static_cast<int>((xl+of+qRound(10/sc)) * sc), QString::number(xl / iter * 10));
p.drawText(9, qRound((xl+of+10/sc) * sc), QString::number(xl / iter * 10 / cor));
break;
}
p.restore();
}
}
}
p.end();
}
/** Zeichnet den Pfeil */
150,4 → 179,3
p.end();
oldMark = Markp;
}
 
/trunk/Scribus/scribus/guidemanager.cpp
78,7 → 78,7
Layout6 = new QHBoxLayout(0, 0, 6, "Layout6");
 
HorGroup = new QGroupBox(this, "HorGroup");
HorGroup->setTitle(tr("Horizontal Guides"));
HorGroup->setTitle( tr("Horizontal Guides"));
HorGroup->setColumnLayout(0, Qt::Vertical);
HorGroup->layout()->setSpacing(6);
HorGroup->layout()->setMargin(11);
92,7 → 92,7
Layout4 = new QHBoxLayout(0, 0, 6, "Layout4");
 
TextLabel2 = new QLabel(HorGroup, "TextLabel2");
TextLabel2->setText(tr("X-Pos:"));
TextLabel2->setText( tr("X-Pos:"));
Layout4->addWidget(TextLabel2);
 
HorSpin = new MSpinBox(HorGroup, 4);
106,7 → 106,7
Layout3 = new QHBoxLayout(0, 0, 6, "Layout3");
 
HorSet = new QPushButton(HorGroup, "HorSet");
HorSet->setText(tr("Add"));
HorSet->setText( tr("Add"));
HorSet->setAutoDefault(false);
Layout3->addWidget(HorSet);
 
120,7 → 120,7
Layout6->addWidget(HorGroup);
 
VerGroup = new QGroupBox(this, "VerGroup");
VerGroup->setTitle(tr("Vertical Guides"));
VerGroup->setTitle( tr("Vertical Guides"));
VerGroup->setColumnLayout(0, Qt::Vertical);
VerGroup->layout()->setSpacing(6);
VerGroup->layout()->setMargin(11);
134,7 → 134,7
Layout2 = new QHBoxLayout(0, 0, 6, "Layout2");
 
TextLabel1 = new QLabel(VerGroup, "TextLabel1");
TextLabel1->setText(tr("Y-Pos:"));
TextLabel1->setText( tr("Y-Pos:"));
Layout2->addWidget(TextLabel1);
 
VerSpin = new MSpinBox(VerGroup, 4);
148,12 → 148,12
Layout1 = new QHBoxLayout(0, 0, 6, "Layout1");
 
VerSet = new QPushButton(VerGroup, "VerSet");
VerSet->setText(tr("Add"));
VerSet->setText( tr("Add"));
VerSet->setAutoDefault(false);
Layout1->addWidget(VerSet);
 
VerDel = new QPushButton(VerGroup, "VerDel");
VerDel->setText(tr("Delete"));
VerDel->setText( tr("Delete"));
VerDel->setAutoDefault(false);
Layout1->addWidget(VerDel);
 
164,7 → 164,7
GuideManagerLayout->addLayout(Layout6);
 
Lock = new QCheckBox(this, "Lock");
Lock->setText(tr("Lock Guides"));
Lock->setText( tr("Lock Guides"));
Lock->setChecked(LocLocked);
GuideManagerLayout->addWidget(Lock);
 
174,7 → 174,7
Layout5->addItem(spacer);
 
OK = new QPushButton(this, "OK");
OK->setText(tr("OK"));
OK->setText( tr("OK"));
OK->setDefault(true);
Layout5->addWidget(OK );
 
182,7 → 182,7
Layout5->addItem(spacer_2);
 
Cancel = new QPushButton(this, "Cancel");
Cancel->setText(tr("Cancel"));
Cancel->setText( tr("Cancel"));
Layout5->addWidget(Cancel);
 
QSpacerItem* spacer_3 = new QSpacerItem( 0, 0, QSizePolicy::Expanding, QSizePolicy::Minimum );
/trunk/Scribus/scribus/pageitem.cpp
261,9 → 261,9
}
Doc->Vorlagen[0].Ausri = Ausrich;
pf.begin(Parent);
pf.translate(static_cast<int>(Xpos*sc), static_cast<int>(Ypos*sc));
pf.scale(static_cast<double>(sc), static_cast<double>(sc));
pf.rotate(static_cast<double>(Rot));
pf.translate(qRound(Xpos*sc), qRound(Ypos*sc));
pf.scale(sc, sc);
pf.rotate(Rot);
if (!Doc->RePos)
pf.setClipRect(!e.isEmpty() ? e : OwnPage->ViewReg().boundingRect());
bool doStroke = true;
271,7 → 271,7
p->save();
p->translate(-e.x(), -e.y());
p->translate(Xpos*sc, Ypos*sc);
p->rotate(static_cast<double>(Rot));
p->rotate(Rot);
p->setLineWidth(Pwidth);
if (Pcolor != "None")
{
594,7 → 594,6
else
chs = hl->csize;
desc2 = -(*Doc->AllFonts)[hl->cfont]->numDescender * (chs / 10.0);
// CurY = Doc->Vorlagen[hl->cab].LineSpa+TExtra+lineCorr-desc2;
CurY = TExtra+lineCorr;
}
else
641,10 → 640,7
else
DropCmode = false;
if (DropCmode)
{
DropLines = Doc->Vorlagen[absa].DropLin;
// CurY += Doc->Vorlagen[absa].LineSpa * (DropLines-1);
}
break;
}
else
666,14 → 662,9
CurX += Doc->Vorlagen[absa].Indent;
CurY += Doc->Vorlagen[absa].Avor;
if (DropCmode)
{
DropLines = Doc->Vorlagen[absa].DropLin;
// CurY += Doc->Vorlagen[absa].LineSpa * (DropLines-1);
}
}
}
// if ((Doc->Vorlagen[0].LineSpa != Doc->Vorlagen[absa].LineSpa) && (a == 0))
// CurY += Doc->Vorlagen[absa].Avor;
if (LiList.count() == 0)
{
if ((a > 0) && (Ptext.at(a-1)->ch == QChar(13)))
767,10 → 758,7
CurY = TExtra+lineCorr;
CurY += Doc->Vorlagen[hl->cab].Avor;
if (DropCmode)
{
DropLines = Doc->Vorlagen[hl->cab].DropLin;
// CurY += Doc->Vorlagen[hl->cab].LineSpa * (DropLines-1);
}
}
else
CurX += Doc->Vorlagen[hl->cab].Indent;
907,7 → 895,13
maxDY = CurY;
maxDX = CurX;
CurY -= Doc->Vorlagen[absa].LineSpa * (DropLines-1);
cm = QRegion(pf.xForm(QRect(qRound(hl->xp), qRound(maxDY-DropLines*Doc->Vorlagen[absa].LineSpa), qRound(wide), qRound(DropLines*Doc->Vorlagen[absa].LineSpa))));
QPointArray tcli;
tcli.resize(4);
tcli.setPoint(0, QPoint(qRound(hl->xp), qRound(maxDY-DropLines*Doc->Vorlagen[absa].LineSpa)));
tcli.setPoint(1, QPoint(qRound(hl->xp+wide), qRound(maxDY-DropLines*Doc->Vorlagen[absa].LineSpa)));
tcli.setPoint(2, QPoint(qRound(hl->xp+wide), qRound(maxDY)));
tcli.setPoint(3, QPoint(qRound(hl->xp), qRound(maxDY)));
cm = QRegion(pf.xForm(tcli));
cl = cl.subtract(cm);
}
if ((hl->ch == QChar(13)) || (outs))
/trunk/Scribus/scribus/druck.cpp
485,7 → 485,7
if (it.data().KeyW == "orientation")
PrinterOpts += " -o landscape";
else
PrinterOpts += " -o" +
PrinterOpts += " -o " +
it.data().KeyW+"="+dia->FlagsOpt.at(it.data().Cnum)->currentText();
}
}
/trunk/Scribus/scribus/libabout/about.cpp
54,7 → 54,7
tabLayout1->addWidget( PixmapLabel1 );
BuildID = new QLabel( tab, "BB" );
BuildID->setAlignment(Qt::AlignCenter);
QString bu = tr("%1. %2 %3 ").arg(30).arg("January").arg(2004);
QString bu = tr("%1. %2 %3 ").arg(1).arg("February").arg(2004);
#ifdef HAVE_CMS
bu += "C";
#else
/trunk/Scribus/scribus/Makefile.am
15,6 → 15,12
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/scribus.h $(prefix)/include/scribus/scribus.h
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/styleselect.h $(prefix)/include/scribus/styleselect.h
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/alignselect.h $(prefix)/include/scribus/alignselect.h
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/shadebutton.h $(prefix)/include/scribus/shadebutton.h
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/splash.h $(prefix)/include/scribus/splash.h
$(mkinstalldirs) $(prefix)/include/scribus/
$(INSTALL_DATA) $(srcdir)/fontcombo.h $(prefix)/include/scribus/fontcombo.h
94,6 → 100,9
uninstall-local:
-rm -f $(prefix)/lib/scribus/rgbscribus.txt
-rm -f $(prefix)/include/scribus/scribus.h
-rm -f $(prefix)/include/scribus/styleselect.h
-rm -f $(prefix)/include/scribus/alignselect.h
-rm -f $(prefix)/include/scribus/shadebutton.h
-rm -f $(prefix)/include/scribus/splash.h
-rm -f $(prefix)/include/scribus/fontcombo.h
-rm -f $(prefix)/include/scribus/scribusdoc.h
/trunk/Scribus/scribus/hruler.cpp
58,23 → 58,54
int pc, xx;
double of, xl, iter, iter2;
double sc = doku->Scale;
int cor = 1;
switch (doku->Einheit)
{
case 0:
iter = 10.0;
if (sc > 1)
cor = 2;
if (sc > 4)
cor = 10;
iter = 10.0 / cor;
iter2 = iter * 10.0;
break;
case 1:
iter = (10.0 / 25.4) * 72.0;
if (sc > 1)
cor = 10;
iter = ((10.0 / 25.4) * 72.0) / cor;
iter2 = iter * 10.0;
break;
case 2:
iter = 18.0;
iter2 = 72.0;
if (sc > 1)
{
cor = 2;
iter = 9.0;
iter2 = 36.0;
}
if (sc > 4)
{
iter = 9.0;
iter2 = 18.0;
cor = 4;
}
break;
case 3:
iter = 12.0;
iter2 = 120.0;
if (sc > 1)
{
cor = 1;
iter = 12.0;
iter2 = 60.0;
}
if (sc > 4)
{
cor = 2;
iter = 6.0;
iter2 = 12.0;
}
break;
}
QPainter p;
95,7 → 126,6
p.setBrush(black);
p.setPen(black);
p.setFont(font());
p.scale(sc, 1.0);
((doku->PageFP) && (doku->PagesSbS)) ? pc = 2 : pc = 1;
if (doku->MasterP)
pc = 1;
103,25 → 133,22
{
of = xx * (doku->PageB+30.0);
for (xl = 0; xl < doku->PageB; xl += iter)
p.drawLine(static_cast<int>(xl+of), 18, static_cast<int>(xl+of), 24);
p.drawLine(qRound((xl+of)*sc), 18, qRound((xl+of)*sc), 24);
for (xl = 0; xl < doku->PageB+(iter2/2); xl += iter2)
{
p.drawLine(static_cast<int>(xl+of), 11, static_cast<int>(xl+of), 24);
p.save();
p.scale(1.0 / sc, 1.0);
p.drawLine(qRound((xl+of)*sc), 11, qRound((xl+of)*sc), 24);
switch (doku->Einheit)
{
case 2:
p.drawText(static_cast<int>((xl+of+qRound(2/sc)) * sc), 17, QString::number(xl / iter2));
p.drawText(qRound((xl+of+2/sc) * sc), 17, QString::number(xl / iter2 / cor));
break;
case 3:
p.drawText(static_cast<int>((xl+of+qRound(2/sc)) * sc), 17, QString::number(xl / iter));
p.drawText(qRound((xl+of+2/sc) * sc), 17, QString::number(xl / iter / cor));
break;
default:
p.drawText(static_cast<int>((xl+of+qRound(2/sc)) * sc), 17, QString::number(xl / iter * 10));
p.drawText(qRound((xl+of+2/sc) * sc), 17, QString::number(xl / iter * 10 / cor));
break;
}
p.restore();
}
}
}
/trunk/Scribus/scribus/scribus.cpp
1895,7 → 1895,7
#endif
Mpal->Cpal->SetColors(doc->PageColors);
Mpal->Cpal->ChooseGrad(0);
ActWin->setCaption( tr(doc->DocName));
ActWin->setCaption(doc->DocName);
ShadeMenu->setItemChecked(ShadeMenu->idAt(11), true);
Mpal->SetDoc(doc);
Mpal->updateCList();
2031,7 → 2031,7
}
Mpal->Cpal->SetColors(doc->PageColors);
Mpal->Cpal->ChooseGrad(0);
ActWin->setCaption( tr(doc->DocName));
ActWin->setCaption( QString::fromLocal8Bit(doc->DocName) );
ShadeMenu->setItemChecked(ShadeMenu->idAt(11), true);
Mpal->SetDoc(doc);
Mpal->updateCList();
2891,7 → 2891,6
 
bool ScribusApp::DoFileClose()
{
uint a;
setAppMode(1);
doc->ASaveTimer->stop();
disconnect(doc->ASaveTimer, SIGNAL(timeout()), doc->WinHan, SLOT(slotAutoSave()));
2985,10 → 2984,6
#endif
}
view->close();
for (a = 0; a<view->Pages.count(); ++a)
{
delete view->Pages.at(a);
}
HaveDoc--;
view = NULL;
delete doc;
5664,11 → 5659,11
uint max = QMIN(Prefs.RecentDCount, Prefs.RecentDocs.count());
for (uint m = 0; m < max; ++m)
{
QFileInfo fd(Prefs.RecentDocs[m]);
QFileInfo fd(QString::fromUtf8(Prefs.RecentDocs[m]));
if (fd.exists())
{
RecentDocs.append(Prefs.RecentDocs[m]);
recentMenu->insertItem(Prefs.RecentDocs[m]);
recentMenu->insertItem(QString::fromUtf8(Prefs.RecentDocs[m]));
}
}
Mpal->move(Prefs.Mpalx, Prefs.Mpaly);
/trunk/Scribus/scribus/mspinbox.cpp
154,6 → 154,9
 
void MSpinBox::setDecimals(int deci)
{
double oldDeci = static_cast<double>(Decimals);
double oldMin = static_cast<double>(QSpinBox::minValue());
double oldMax = static_cast<double>(QSpinBox::maxValue());
Decimals = deci;
QSpinBox::setLineStep(Decimals);
if (deci < 10)
166,6 → 169,8
Width = 3;
if (deci > 9999)
Width = 4;
QSpinBox::setMinValue(qRound((oldMin / oldDeci) * Decimals));
QSpinBox::setMaxValue(qRound((oldMax / oldDeci) * Decimals));
}
 
/*!
/trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp
146,7 → 146,7
Carrier->HaveNewSel(Carrier->doc->ActPage->SelItem.at(0)->PType);
else
Carrier->HaveNewSel(-1);
Carrier->doc->ActPage->repaint();
Carrier->view->DrawNew();
}
}
 
181,7 → 181,7
Carrier->HaveNewSel(Carrier->doc->ActPage->SelItem.at(0)->PType);
else
Carrier->HaveNewSel(-1);
Carrier->doc->ActPage->repaint();
Carrier->view->DrawNew();
}
}
 
188,11 → 188,11
void MenuTest::slotRunScriptFile(QString fileName)
{
Carrier->ScriptRunning = true;
qApp->setOverrideCursor(QCursor(waitCursor), true);
char* comm[1];
QFileInfo fi(fileName);
QCString na = fi.fileName().latin1();
QDir::setCurrent(fi.dirPath(true));
// PyThreadState *stateo = PyThreadState_Get();
PyThreadState *stateo = PyEval_SaveThread();
PyThreadState *state = Py_NewInterpreter();
initscribus(Carrier);
205,11 → 205,13
Py_EndInterpreter(state);
PyEval_RestoreThread(stateo);
Carrier->ScriptRunning = false;
qApp->setOverrideCursor(QCursor(arrowCursor), true);
}
 
QString MenuTest::slotRunScript(QString Script)
{
Carrier->ScriptRunning = true;
qApp->setOverrideCursor(QCursor(waitCursor), true);
char* comm[1];
QString cm;
InValue = Script;
248,6 → 250,7
else
pcon->OutWin->Prompt = "...";
Carrier->ScriptRunning = false;
qApp->setOverrideCursor(QCursor(arrowCursor), true);
return RetString;
}
 
286,7 → 289,7
else
Carrier->HaveNewSel(-1);
Carrier->Sepal->Rebuild();
Carrier->doc->ActPage->repaint();
Carrier->view->DrawNew();
}
}