|
pdfoptions_2024-11-22_01.patch (7,112 bytes)
Index: resources/iconsets/1_7_0/1_7_0.xml
===================================================================
--- resources/iconsets/1_7_0/1_7_0.xml (Revision 26446)
+++ resources/iconsets/1_7_0/1_7_0.xml (Arbeitskopie)
@@ -138,8 +138,10 @@
<icon id="u_group.png" file="16/object-group.svg" /><!-- Outliner -->
<icon id="u_undo16.png" file="16/action-undo.svg" /><!-- Barcode -->
<icon id="ungroup.png" file="16/object-ungroup.svg" />
+ <icon id="add" file="16/action-add.svg" />
<icon id="collapse" file="16/action-chevron-right.svg" />
<icon id="context-menu" file="16/action-menu.svg" />
+ <icon id="delete" file="16/action-delete.svg" />
<icon id="delete-selected" file="16/action-delete-selected.svg" />
<icon id="erase-shadow-off" file="16/action-shadow-erase-off.svg" />
<icon id="erase-shadow-on" file="16/action-shadow-erase-on.svg" />
@@ -146,15 +148,15 @@
<icon id="expand" file="16/action-chevron-down.svg" />
<icon id="inherit-opacity-off" file="16/action-inherit-opacity-off.svg" />
<icon id="inherit-opacity-on" file="16/action-inherit-opacity-on.svg" />
+ <icon id="name" file="16/object-name.svg" />
+ <icon id="remove" file="16/action-remove.svg" />
<icon id="reset" file="16/action-reload.svg" />
<icon id="reset-style-changes" file="16/action-reload.svg" /> <!-- 16/action-revert-changes.svg -->
<icon id="scale-height" file="16/action-scale-height.svg" />
<icon id="scale-width" file="16/action-scale-width.svg" />
+ <icon id="settings" file="16/properties-external-tools.svg" />
<icon id="swap" file="16/action-swap.svg" />
<icon id="toggle-object-coordination" file="16/object-xycoordination.svg" />
- <icon id="context-menu" file="16/action-menu.svg" />
- <icon id="scale-width" file="16/action-scale-width.svg" />
- <icon id="scale-height" file="16/action-scale-height.svg" />
<icon id="whitespace-review-mode" file="16/action-whitespace-review.svg" />
<!-- Alerts -->
@@ -422,7 +424,8 @@
<icon id="16/annot3d.png" file="16/pdf-annotation-3d.svg" />
<icon id="22/annot3d.png" file="16/pdf-annotation-3d.svg" />
<icon id="goto16.png" file="16/pdf-annotation-link.svg" />
- <icon id="goto.png" file="16/pdf-annotation-link.svg" />
+ <icon id="goto.png" file="16/pdf-annotation-link.svg" />
+ <icon id="pdf-bookmark" file="16/panel-bookmarks.svg" />
<!-- Picture Browser -->
<icon id="doc.png" file="16/file-new.svg" />
Index: scribus/ui/propertiespalette_attributes.cpp
===================================================================
--- scribus/ui/propertiespalette_attributes.cpp (Revision 26446)
+++ scribus/ui/propertiespalette_attributes.cpp (Arbeitskopie)
@@ -24,10 +24,13 @@
connect(ScQApp, SIGNAL(iconSetChanged()), this, SLOT(iconSetChange()));
connect(ScQApp, SIGNAL(labelVisibilityChanged(bool)), this, SLOT(toggleLabelVisibility(bool)));
-
connect(nameEdit , SIGNAL(Leaved()) , this, SLOT(handleNewName()));
connect(noPrint , SIGNAL(clicked()), this, SLOT(handlePrint()));
+ connect(buttonPDFBookmark , SIGNAL(clicked()), this, SLOT(handlePDFBookmark()));
+ connect(buttonPDFAnnotation , SIGNAL(clicked()), this, SLOT(handlePDFAnnotation()));
+ connect(buttonPDFAnnotationSettings , SIGNAL(clicked()), this, SLOT(handlePDFAnnotationSettings()));
+
}
void PropertiesPalette_Attributes::setMainWindow(ScribusMainWindow* mw)
@@ -102,8 +105,10 @@
if (!m_doc)
setDoc(item->doc());
- disconnect(nameEdit, SIGNAL(Leaved()), this, SLOT(handleNewName()));
- disconnect(noPrint, SIGNAL(clicked()), this, SLOT(handlePrint()));
+ QSignalBlocker sigName(nameEdit);
+ QSignalBlocker sigPrint(noPrint);
+ QSignalBlocker sigPDFBookmark(buttonPDFBookmark);
+ QSignalBlocker sigPDFAnnotation(buttonPDFAnnotation);
m_haveItem = false;
m_item = item;
@@ -111,8 +116,9 @@
nameEdit->setText(m_item->itemName());
noPrint->setChecked(!item->printEnabled());
- connect(nameEdit, SIGNAL(Leaved()), this, SLOT(handleNewName()));
- connect(noPrint , SIGNAL(clicked()), this, SLOT(handlePrint()), Qt::UniqueConnection);
+ buttonPDFBookmark->setChecked(m_item->isPDFBookmark());
+ buttonPDFAnnotation->setChecked(m_item->isAnnotation());
+ buttonPDFAnnotationSettings->setEnabled(buttonPDFAnnotation->isChecked());
m_haveItem = true;
@@ -152,21 +158,16 @@
void PropertiesPalette_Attributes::toggleLabelVisibility(bool visibility)
{
- formWidget->setLabelVisibility(visibility);
+ labelName->setLabelVisibility(visibility);
labelExport->setLabelVisibility(visibility);
+ labelPDFOptions->setLabelVisibility(visibility);
}
-void PropertiesPalette_Attributes::showPrintingEnabled(bool isPrintingEnabled)
-{
- noPrint->setChecked(!isPrintingEnabled);
-}
-
-
void PropertiesPalette_Attributes::handlePrint()
{
if (!m_haveDoc || !m_haveItem || !m_ScMW || m_ScMW->scriptIsRunning())
return;
- m_ScMW->scrActions["itemPrintingEnabled"]->toggle();
+ m_doc->itemSelection_TogglePrintEnabled();
}
void PropertiesPalette_Attributes::handleNewName()
@@ -216,6 +217,27 @@
}
}
+void PropertiesPalette_Attributes::handlePDFBookmark()
+{
+ if (!m_haveDoc || !m_haveItem || !m_ScMW || m_ScMW->scriptIsRunning())
+ return;
+ m_doc->itemSelection_ToggleBookMark();
+}
+
+void PropertiesPalette_Attributes::handlePDFAnnotation()
+{
+ if (!m_haveDoc || !m_haveItem || !m_ScMW || m_ScMW->scriptIsRunning())
+ return;
+ m_doc->itemSelection_ToggleAnnotation();
+}
+
+void PropertiesPalette_Attributes::handlePDFAnnotationSettings()
+{
+ if (!m_haveDoc || !m_haveItem || !m_ScMW || m_ScMW->scriptIsRunning())
+ return;
+ m_ScMW->ModifyAnnot();
+}
+
void PropertiesPalette_Attributes::changeEvent(QEvent *e)
{
if (e->type() == QEvent::LanguageChange)
@@ -230,11 +252,16 @@
{
IconManager& im = IconManager::instance();
- QIcon a2;
- a2.addPixmap(im.loadPixmap("NoPrint.png"), QIcon::Normal, QIcon::On);
- a2.addPixmap(im.loadPixmap("16/document-print.png"), QIcon::Normal, QIcon::Off);
- noPrint->setIcon(a2);
+ QIcon icoPrint;
+ icoPrint.addPixmap(im.loadPixmap("NoPrint.png"), QIcon::Normal, QIcon::On);
+ icoPrint.addPixmap(im.loadPixmap("16/document-print.png"), QIcon::Normal, QIcon::Off);
+ noPrint->setIcon(icoPrint);
+ labelName->setPixmap(im.loadPixmap("name"));
+ buttonPDFBookmark->setIcon(im.loadPixmap("pdf-bookmark"));
+ buttonPDFAnnotation->setIcon(im.loadPixmap("16/pdf-annotations.png"));
+ buttonPDFAnnotationSettings->setIcon(im.loadIcon("settings"));
+
}
void PropertiesPalette_Attributes::languageChange()
Index: scribus/ui/propertiespalette_attributes.h
===================================================================
--- scribus/ui/propertiespalette_attributes.h (Revision 26446)
+++ scribus/ui/propertiespalette_attributes.h (Arbeitskopie)
@@ -36,13 +36,14 @@
void languageChange();
void toggleLabelVisibility(bool visibility);
- void showPrintingEnabled(bool isPrintingEnabled);
-
void handleSelectionChanged();
private slots:
void handlePrint();
void handleNewName();
+ void handlePDFBookmark();
+ void handlePDFAnnotation();
+ void handlePDFAnnotationSettings();
protected:
bool m_haveDoc {false};
|