LibreOffice Module sd (master) 1
pubdlg.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#include <com/sun/star/beans/PropertyValue.hpp>
24#include <vcl/image.hxx>
25#include <vcl/svapp.hxx>
26#include <vcl/weld.hxx>
27#include <sal/log.hxx>
28#include <svtools/valueset.hxx>
29#include <svtools/colrdlg.hxx>
30#include <tools/debug.hxx>
31#include <tools/urlobj.hxx>
33#include <sdiocmpt.hxx>
34#include <sfx2/docfile.hxx>
35#include <pres.hxx>
38
39#include <sdresid.hxx>
40#include <strings.hrc>
41#include <pubdlg.hxx>
42#include "htmlattr.hxx"
43#include "htmlex.hxx"
44#include "htmlpublishmode.hxx"
45#include <helpids.h>
46#include "buttonset.hxx"
47#include <strings.hxx>
48
49using namespace com::sun::star::uno;
50using namespace com::sun::star::beans;
51
52#define NOOFPAGES 6
53
54//ID for the config-data with the HTML-settings
55const sal_uInt16 nMagic = sal_uInt16(0x1977);
56
57// Key for the soffice.ini
58constexpr OUStringLiteral KEY_QUALITY = u"JPG-EXPORT-QUALITY";
59
60// The Help-IDs of the pages
61constexpr rtl::OUStringConstExpr aPageHelpIds[NOOFPAGES] =
62{
69};
70
71static SvStream& operator >> (SvStream& rIn, SdPublishingDesign& rDesign);
72
73static SvStream& WriteSdPublishingDesign(SvStream& rOut, const SdPublishingDesign& rDesign);
74
75// This class has all the settings for the HTML-export autopilot
77{
78public:
79 OUString m_aDesignName;
80
82
83 // special WebCast options
85 OUString m_aCGI;
86 OUString m_aURL;
87
88 // special Kiosk options
90 sal_uInt32 m_nSlideDuration;
92
93 // special HTML options
96
97 // misc options
98 sal_uInt16 m_nResolution;
103
104 // title page information
105 OUString m_aAuthor;
106 OUString m_aEMail;
107 OUString m_aWWW;
108 OUString m_aMisc;
110 bool m_bCreated; // not used
111
112 // buttons and colorscheme
113 sal_Int16 m_nButtonThema;
122
124
125 bool operator ==(const SdPublishingDesign & rDesign) const;
126 friend SvStream& operator >> (SvStream& rIn, SdPublishingDesign& rDesign);
127 friend SvStream& WriteSdPublishingDesign(SvStream& rOut, const SdPublishingDesign& rDesign);
128};
129
130// load Default-settings
132 : m_eMode(PUBLISH_HTML)
133 , m_eScript(SCRIPT_ASP)
134 , m_bAutoSlide(true)
135 , m_nSlideDuration(15)
136 , m_bEndless(true)
137 , m_bContentPage(true)
138 , m_bNotes(true)
139 , m_nResolution(PUB_LOWRES_WIDTH)
140 , m_eFormat(FORMAT_PNG)
141 , m_bSlideSound(true)
142 , m_bHiddenSlides(false)
143 , m_bDownload(false)
144 , m_bCreated(false)
145 , m_nButtonThema(-1)
146 , m_bUserAttr(false)
147 , m_aBackColor(COL_WHITE)
148 , m_aTextColor(COL_BLACK)
149 , m_aLinkColor(COL_BLUE)
150 , m_aVLinkColor(COL_LIGHTGRAY)
151 , m_aALinkColor(COL_GRAY)
152 , m_bUseAttribs(true)
153 , m_bUseColor(true)
154{
155 FilterConfigItem aFilterConfigItem(u"Office.Common/Filter/Graphic/Export/JPG");
156 sal_Int32 nCompression = aFilterConfigItem.ReadInt32( KEY_QUALITY, 75 );
157 m_aCompression = OUString::number(nCompression) + "%";
158
159 SvtUserOptions aUserOptions;
160 m_aAuthor = aUserOptions.GetFirstName();
161 if (!m_aAuthor.isEmpty() && !aUserOptions.GetLastName().isEmpty())
162 m_aAuthor += " ";
163 m_aAuthor += aUserOptions.GetLastName();
164 m_aEMail = aUserOptions.GetEmail();
165}
166
167// Compares the values without paying attention to the name
169{
170 return
171 (
172 m_eMode == rDesign.m_eMode &&
173 m_nResolution == rDesign.m_nResolution &&
174 m_aCompression == rDesign.m_aCompression &&
175 m_eFormat == rDesign.m_eFormat &&
176 m_bHiddenSlides == rDesign.m_bHiddenSlides &&
177 ( // compare html options
179 (
180 m_bContentPage == rDesign.m_bContentPage &&
181 m_bNotes == rDesign.m_bNotes &&
182 m_aAuthor == rDesign.m_aAuthor &&
183 m_aEMail == rDesign.m_aEMail &&
184 m_aWWW == rDesign.m_aWWW &&
185 m_aMisc == rDesign.m_aMisc &&
186 m_bDownload == rDesign.m_bDownload &&
187 m_nButtonThema == rDesign.m_nButtonThema &&
188 m_bUserAttr == rDesign.m_bUserAttr &&
189 m_aBackColor == rDesign.m_aBackColor &&
190 m_aTextColor == rDesign.m_aTextColor &&
191 m_aLinkColor == rDesign.m_aLinkColor &&
192 m_aVLinkColor == rDesign.m_aVLinkColor &&
193 m_aALinkColor == rDesign.m_aALinkColor &&
194 m_bUseAttribs == rDesign.m_bUseAttribs &&
195 m_bSlideSound == rDesign.m_bSlideSound &&
196 m_bUseColor == rDesign.m_bUseColor
197 )
198 ) &&
199 ( // compare kiosk options
200 (m_eMode != PUBLISH_KIOSK) ||
201 (
202 m_bAutoSlide == rDesign.m_bAutoSlide &&
203 m_bSlideSound == rDesign.m_bSlideSound &&
204 (
205 !m_bAutoSlide ||
206 (
208 m_bEndless == rDesign.m_bEndless
209 )
210 )
211 )
212 ) &&
213 ( // compare WebCast options
215 (
216 m_eScript == rDesign.m_eScript &&
217 (
219 (
220 m_aURL == rDesign.m_aURL &&
221 m_aCGI == rDesign.m_aCGI
222 )
223 )
224 )
225 )
226 );
227}
228
229// Load the design from the stream
231{
232 SdIOCompat aIO(rIn, StreamMode::READ);
233
234 sal_uInt16 nTemp16;
235 tools::GenericTypeSerializer aSerializer(rIn);
236
238 RTL_TEXTENCODING_UTF8);
239 rIn.ReadUInt16( nTemp16 );
240 rDesign.m_eMode = static_cast<HtmlPublishMode>(nTemp16);
241 rIn.ReadCharAsBool( rDesign.m_bContentPage );
242 rIn.ReadCharAsBool( rDesign.m_bNotes );
243 rIn.ReadUInt16( rDesign.m_nResolution );
245 RTL_TEXTENCODING_UTF8);
246 rIn.ReadUInt16( nTemp16 );
247 rDesign.m_eFormat = static_cast<PublishingFormat>(nTemp16);
249 RTL_TEXTENCODING_UTF8);
251 RTL_TEXTENCODING_UTF8);
253 RTL_TEXTENCODING_UTF8);
255 RTL_TEXTENCODING_UTF8);
256 rIn.ReadCharAsBool( rDesign.m_bDownload );
257 rIn.ReadCharAsBool( rDesign.m_bCreated ); // not used
258 rIn.ReadInt16( rDesign.m_nButtonThema );
259 rIn.ReadCharAsBool( rDesign.m_bUserAttr );
260 aSerializer.readColor(rDesign.m_aBackColor);
261 aSerializer.readColor(rDesign.m_aTextColor);
262 aSerializer.readColor(rDesign.m_aLinkColor);
263 aSerializer.readColor(rDesign.m_aVLinkColor);
264 aSerializer.readColor(rDesign.m_aALinkColor);
265 rIn.ReadCharAsBool( rDesign.m_bUseAttribs );
266 rIn.ReadCharAsBool( rDesign.m_bUseColor );
267
268 rIn.ReadUInt16( nTemp16 );
269 rDesign.m_eScript = static_cast<PublishingScript>(nTemp16);
271 RTL_TEXTENCODING_UTF8);
273 RTL_TEXTENCODING_UTF8);
274
275 rIn.ReadCharAsBool( rDesign.m_bAutoSlide );
276 rIn.ReadUInt32( rDesign.m_nSlideDuration );
277 rIn.ReadCharAsBool( rDesign.m_bEndless );
278 rIn.ReadCharAsBool( rDesign.m_bSlideSound );
279 rIn.ReadCharAsBool( rDesign.m_bHiddenSlides );
280
281 return rIn;
282}
283
284// Set the design to the stream
286{
287 // The last parameter is the versionnumber of the code
288 SdIOCompat aIO(rOut, StreamMode::WRITE, 0);
289
290 tools::GenericTypeSerializer aSerializer(rOut);
291
292 // Name
294 RTL_TEXTENCODING_UTF8);
295
296 rOut.WriteUInt16( rDesign.m_eMode );
297 rOut.WriteBool( rDesign.m_bContentPage );
298 rOut.WriteBool( rDesign.m_bNotes );
299 rOut.WriteUInt16( rDesign.m_nResolution );
301 RTL_TEXTENCODING_UTF8);
302 rOut.WriteUInt16( rDesign.m_eFormat );
304 RTL_TEXTENCODING_UTF8);
306 RTL_TEXTENCODING_UTF8);
308 RTL_TEXTENCODING_UTF8);
310 RTL_TEXTENCODING_UTF8);
311 rOut.WriteBool( rDesign.m_bDownload );
312 rOut.WriteBool( rDesign.m_bCreated ); // not used
313 rOut.WriteInt16( rDesign.m_nButtonThema );
314 rOut.WriteBool( rDesign.m_bUserAttr );
315 aSerializer.writeColor(rDesign.m_aBackColor);
316 aSerializer.writeColor(rDesign.m_aTextColor);
317 aSerializer.writeColor(rDesign.m_aLinkColor);
318 aSerializer.writeColor(rDesign.m_aVLinkColor);
319 aSerializer.writeColor(rDesign.m_aALinkColor);
320 rOut.WriteBool( rDesign.m_bUseAttribs );
321 rOut.WriteBool( rDesign.m_bUseColor );
322
323 rOut.WriteUInt16( rDesign.m_eScript );
325 RTL_TEXTENCODING_UTF8);
327 RTL_TEXTENCODING_UTF8);
328
329 rOut.WriteBool( rDesign.m_bAutoSlide );
330 rOut.WriteUInt32( rDesign.m_nSlideDuration );
331 rOut.WriteBool( rDesign.m_bEndless );
332 rOut.WriteBool( rDesign.m_bSlideSound );
333 rOut.WriteBool( rDesign.m_bHiddenSlides );
334
335 return rOut;
336}
337
338namespace {
339
340// Dialog for the entry of the name of the design
341class SdDesignNameDlg : public weld::GenericDialogController
342{
343private:
344 std::unique_ptr<weld::Entry> m_xEdit;
345 std::unique_ptr<weld::Button> m_xBtnOK;
346
347public:
348 SdDesignNameDlg(weld::Window* pWindow, const OUString& aName );
349 OUString GetDesignName() const;
350 DECL_LINK(ModifyHdl, weld::Entry&, void);
351};
352
353}
354
355// SdPublishingDlg Methods
356
358 : GenericDialogController(pWindow, "modules/simpress/ui/publishingdialog.ui", "PublishingDialog")
359 , m_xPage1_Designs(m_xBuilder->weld_tree_view("designsTreeview"))
360 , m_xPage2_Standard_FB(m_xBuilder->weld_image("standardFBImage"))
361 , m_xPage2_Frames_FB(m_xBuilder->weld_image("framesFBImage"))
362 , m_xPage2_Kiosk_FB(m_xBuilder->weld_image("kioskFBImage"))
363 , m_xPage2_WebCast_FB(m_xBuilder->weld_image("webCastFBImage"))
364 , m_xPage4_Misc(m_xBuilder->weld_text_view("miscTextview"))
365 , m_xButtonSet(new ButtonSet())
366 , m_xLastPageButton(m_xBuilder->weld_button("lastPageButton"))
367 , m_xNextPageButton(m_xBuilder->weld_button("nextPageButton"))
368 , m_xFinishButton(m_xBuilder->weld_button("finishButton"))
369 , aAssistentFunc(NOOFPAGES)
370 , m_bButtonsDirty(true)
371 , m_bDesignListDirty(false)
372 , m_pDesign(nullptr)
373{
374 m_bImpress = eDocType == DocumentType::Impress;
375
376 Size aSize(m_xPage2_Standard_FB->get_approximate_digit_width() * 12,
377 m_xPage2_Standard_FB->get_text_height() * 6);
378 m_xPage2_Standard_FB->set_size_request(aSize.Width(), aSize.Height());
379 m_xPage2_Frames_FB->set_size_request(aSize.Width(), aSize.Height());
380 m_xPage2_Kiosk_FB->set_size_request(aSize.Width(), aSize.Height());
381 m_xPage2_WebCast_FB->set_size_request(aSize.Width(), aSize.Height());
382
383 m_xPage4_Misc->set_size_request(m_xPage4_Misc->get_approximate_digit_width() * 40,
384 m_xPage4_Misc->get_height_rows(8));
385
386 m_xPage1_Designs->set_size_request(m_xPage4_Misc->get_approximate_digit_width() * 40,
387 m_xPage4_Misc->get_height_rows(8));
388
389 //Lock down the preferred size based on the
390 //initial max-size configuration
391 aSize = m_xDialog->get_preferred_size();
392 m_xDialog->set_size_request(aSize.Width(), aSize.Height());
393
394 CreatePages();
395 Load();
396
397 // sets the output page
399 m_xLastPageButton->set_sensitive(false);
400
401 // button assignment
402 m_xFinishButton->connect_clicked(LINK(this,SdPublishingDlg,FinishHdl));
403 m_xLastPageButton->connect_clicked(LINK(this,SdPublishingDlg,LastPageHdl));
404 m_xNextPageButton->connect_clicked(LINK(this,SdPublishingDlg,NextPageHdl));
405
406 m_xPage1_NewDesign->connect_toggled(LINK(this,SdPublishingDlg,DesignHdl));
407 m_xPage1_OldDesign->connect_toggled(LINK(this,SdPublishingDlg,DesignHdl));
408 m_xPage1_Designs->connect_changed(LINK(this,SdPublishingDlg,DesignSelectHdl));
409 m_xPage1_DelDesign->connect_clicked(LINK(this,SdPublishingDlg,DesignDeleteHdl));
410
411 m_xPage2_Standard->connect_toggled(LINK(this,SdPublishingDlg,BaseHdl));
412 m_xPage2_Frames->connect_toggled(LINK(this,SdPublishingDlg,BaseHdl));
413 m_xPage2_SingleDocument->connect_toggled(LINK(this,SdPublishingDlg,BaseHdl));
414 m_xPage2_Kiosk->connect_toggled(LINK(this,SdPublishingDlg,BaseHdl));
415 m_xPage2_WebCast->connect_toggled(LINK(this,SdPublishingDlg,BaseHdl));
416
417 m_xPage2_Content->connect_toggled(LINK(this,SdPublishingDlg,ContentHdl));
418
419 m_xPage2_ASP->connect_toggled(LINK(this,SdPublishingDlg,WebServerHdl));
420 m_xPage2_PERL->connect_toggled(LINK(this,SdPublishingDlg,WebServerHdl));
422 m_xPage2_CGI->set_text("/cgi-bin/");
423
424 m_xPage3_Png->connect_toggled(LINK(this,SdPublishingDlg, GfxFormatHdl));
425 m_xPage3_Gif->connect_toggled(LINK(this,SdPublishingDlg, GfxFormatHdl));
426 m_xPage3_Jpg->connect_toggled(LINK(this,SdPublishingDlg, GfxFormatHdl));
427 m_xPage3_Quality->set_sensitive(false);
428
429 m_xPage3_Resolution_1->connect_toggled(LINK(this,SdPublishingDlg, ResolutionHdl ));
430 m_xPage3_Resolution_2->connect_toggled(LINK(this,SdPublishingDlg, ResolutionHdl ));
431 m_xPage3_Resolution_3->connect_toggled(LINK(this,SdPublishingDlg, ResolutionHdl ));
432 m_xPage3_Resolution_4->connect_toggled(LINK(this, SdPublishingDlg, ResolutionHdl));
433
434 m_xPage2_ChgDefault->connect_toggled(LINK(this,SdPublishingDlg, SlideChgHdl));
435 m_xPage2_ChgAuto->connect_toggled(LINK(this,SdPublishingDlg, SlideChgHdl));
436
437 m_xPage5_Buttons->SetSelectHdl(LINK(this,SdPublishingDlg, ButtonsHdl ));
438 m_xPage5_Buttons->SetStyle( m_xPage5_Buttons->GetStyle() | WB_VSCROLL );
439
440 m_xPage6_Back->connect_clicked(LINK(this,SdPublishingDlg, ColorHdl ));
441 m_xPage6_Text->connect_clicked(LINK(this,SdPublishingDlg, ColorHdl ));
442 m_xPage6_Link->connect_clicked(LINK(this,SdPublishingDlg, ColorHdl ));
443 m_xPage6_VLink->connect_clicked(LINK(this,SdPublishingDlg, ColorHdl ));
444 m_xPage6_ALink->connect_clicked(LINK(this,SdPublishingDlg, ColorHdl ));
445
446 m_xPage6_DocColors->set_active(true);
447
448 m_xPage3_Quality->append_text( "25%" );
449 m_xPage3_Quality->append_text( "50%" );
450 m_xPage3_Quality->append_text( "75%" );
451 m_xPage3_Quality->append_text( "100%" );
452
453 m_xPage5_Buttons->SetColCount();
454 m_xPage5_Buttons->SetLineCount( 4 );
455 m_xPage5_Buttons->SetExtraSpacing( 1 );
456
457 for( const auto& rDesign : m_aDesignList )
458 m_xPage1_Designs->append_text(rDesign.m_aDesignName);
459
460 SetDefaults();
461
462 m_xDialog->set_help_id(aPageHelpIds[0]);
463
464 m_xNextPageButton->grab_focus();
465}
466
468{
469}
470
471// Generate dialog controls and embed them in the pages
473{
474 // Page 1
475 m_xPage1 = m_xBuilder->weld_container("page1");
476 m_xPage1_Title = m_xBuilder->weld_label("assignLabel");
477 m_xPage1_NewDesign = m_xBuilder->weld_radio_button("newDesignRadiobutton");
478 m_xPage1_OldDesign = m_xBuilder->weld_radio_button("oldDesignRadiobutton");
479 m_xPage1_DelDesign = m_xBuilder->weld_button("delDesingButton");
480 m_xPage1_Desc = m_xBuilder->weld_label("descLabel");
488
489 // Page 2
490 m_xPage2 = m_xBuilder->weld_container("page2");
491 m_xPage2Frame2 = m_xBuilder->weld_container("page2.2");
492 m_xPage2Frame3 = m_xBuilder->weld_container("page2.3");
493 m_xPage2Frame4 = m_xBuilder->weld_container("page2.4");
494 m_xPage2_Title = m_xBuilder->weld_label("publicationLabel");
495 m_xPage2_Standard = m_xBuilder->weld_radio_button("standardRadiobutton");
496 m_xPage2_Frames = m_xBuilder->weld_radio_button("framesRadiobutton");
497 m_xPage2_SingleDocument = m_xBuilder->weld_radio_button("singleDocumentRadiobutton");
498 m_xPage2_Kiosk = m_xBuilder->weld_radio_button("kioskRadiobutton");
499 m_xPage2_WebCast = m_xBuilder->weld_radio_button("webCastRadiobutton");
514
515 m_xPage2_Title_Html = m_xBuilder->weld_label( "htmlOptionsLabel");
516 m_xPage2_Content = m_xBuilder->weld_check_button("contentCheckbutton");
517 m_xPage2_Notes = m_xBuilder->weld_check_button("notesCheckbutton");
520 if (m_bImpress)
522
523 m_xPage2_Title_WebCast = m_xBuilder->weld_label("webCastLabel");
524 m_xPage2_ASP = m_xBuilder->weld_radio_button("ASPRadiobutton");
525 m_xPage2_PERL = m_xBuilder->weld_radio_button("perlRadiobutton");
526 m_xPage2_URL_txt = m_xBuilder->weld_label("URLTxtLabel");
527 m_xPage2_URL = m_xBuilder->weld_entry("URLEntry");
528 m_xPage2_CGI_txt = m_xBuilder->weld_label("CGITxtLabel");
529 m_xPage2_CGI = m_xBuilder->weld_entry("CGIEntry");
530 m_xPage2_Index_txt = m_xBuilder->weld_label("indexTxtLabel");
531 m_xPage2_Index = m_xBuilder->weld_entry("indexEntry");
532 m_xPage2_Title_Kiosk = m_xBuilder->weld_label("kioskLabel");
533 m_xPage2_ChgDefault = m_xBuilder->weld_radio_button("chgDefaultRadiobutton");
534 m_xPage2_ChgAuto = m_xBuilder->weld_radio_button("chgAutoRadiobutton");
535 m_xPage2_Duration_txt = m_xBuilder->weld_label("durationTxtLabel");
536 m_xPage2_Duration = m_xBuilder->weld_formatted_spin_button("durationSpinbutton");
538 m_xFormatter->SetExtFormat(ExtTimeFieldFormat::LongDuration);
539 m_xPage2_Endless = m_xBuilder->weld_check_button("endlessCheckbutton");
555
556 // Page 3
557 m_xPage3 = m_xBuilder->weld_container("page3");
558 m_xPage3_Title1 = m_xBuilder->weld_label("saveImgAsLabel");
559 m_xPage3_Png = m_xBuilder->weld_radio_button("pngRadiobutton");
560 m_xPage3_Gif = m_xBuilder->weld_radio_button("gifRadiobutton");
561 m_xPage3_Jpg = m_xBuilder->weld_radio_button("jpgRadiobutton");
562 m_xPage3_Quality_txt = m_xBuilder->weld_label("qualityTxtLabel");
563 m_xPage3_Quality= m_xBuilder->weld_combo_box("qualityCombobox");
564 m_xPage3_Title2 = m_xBuilder->weld_label("monitorResolutionLabel");
565 m_xPage3_Resolution_1 = m_xBuilder->weld_radio_button("resolution1Radiobutton");
566 m_xPage3_Resolution_2 = m_xBuilder->weld_radio_button("resolution2Radiobutton");
567 m_xPage3_Resolution_3 = m_xBuilder->weld_radio_button("resolution3Radiobutton");
568 m_xPage3_Resolution_4 = m_xBuilder->weld_radio_button("resolution4Radiobutton");
569 m_xPage3_Title3 = m_xBuilder->weld_label("effectsLabel");
570 m_xPage3_SldSound = m_xBuilder->weld_check_button("sldSoundCheckbutton");
571 m_xPage3_HiddenSlides = m_xBuilder->weld_check_button("hiddenSlidesCheckbutton");
587
588 // Page 4
589 m_xPage4 = m_xBuilder->weld_container("page4");
590 m_xPage4_Title1 = m_xBuilder->weld_label("infTitlePageLabel");
591 m_xPage4_Author_txt = m_xBuilder->weld_label("authorTxtLabel");
592 m_xPage4_Author = m_xBuilder->weld_entry("authorEntry");
593 m_xPage4_Email_txt = m_xBuilder->weld_label("emailTxtLabel");
594 m_xPage4_Email = m_xBuilder->weld_entry("emailEntry");
595 m_xPage4_WWW_txt = m_xBuilder->weld_label("wwwTxtLabel");
596 m_xPage4_WWW = m_xBuilder->weld_entry("wwwEntry");
597 m_xPage4_Title2 = m_xBuilder->weld_label("addInformLabel");
598 m_xPage4_Download = m_xBuilder->weld_check_button("downloadCheckbutton");
609 if(m_bImpress)
611
612 // Page 5
613 m_xPage5 = m_xBuilder->weld_container("page5");
614 m_xPage5_Title = m_xBuilder->weld_label("buttonStyleLabel");
615 m_xPage5_TextOnly = m_xBuilder->weld_check_button("textOnlyCheckbutton");
616 m_xPage5_Buttons.reset(new ValueSet(m_xBuilder->weld_scrolled_window("buttonsDrawingareawin", true)));
617 m_xPage5_ButtonsWnd.reset(new weld::CustomWeld(*m_xBuilder, "buttonsDrawingarea", *m_xPage5_Buttons));
621 aAssistentFunc.InsertControl(5, m_xPage5_Buttons->GetDrawingArea());
622
623 // Page 6
624 m_xPage6 = m_xBuilder->weld_container("page6");
625 m_xPage6_Title = m_xBuilder->weld_label("selectColorLabel");
626 m_xPage6_Default = m_xBuilder->weld_radio_button("defaultRadiobutton");
627 m_xPage6_User = m_xBuilder->weld_radio_button("userRadiobutton");
628 m_xPage6_Back = m_xBuilder->weld_button("backButton");
629 m_xPage6_Text = m_xBuilder->weld_button("textButton");
630 m_xPage6_Link = m_xBuilder->weld_button("linkButton");
631 m_xPage6_VLink = m_xBuilder->weld_button("vLinkButton");
632 m_xPage6_ALink = m_xBuilder->weld_button("aLinkButton");
633 m_xPage6_DocColors = m_xBuilder->weld_radio_button("docColorsRadiobutton");
635 m_xPage6_PreviewWnd.reset(new weld::CustomWeld(*m_xBuilder, "previewDrawingarea", *m_xPage6_Preview));
646 aAssistentFunc.InsertControl(6, m_xPage6_Preview->GetDrawingArea());
647}
648
649// Initialize dialog with default-values
651{
652 SdPublishingDesign aDefault;
653 SetDesign(&aDefault);
654
655 m_xPage1_NewDesign->set_active(true);
656 m_xPage1_OldDesign->set_active(false);
657 UpdatePage();
658}
659
660// Feed the SfxItemSet with the settings of the dialog
662{
663 std::vector< PropertyValue > aProps;
664
665 PropertyValue aValue;
666
667 // Page 2
668 aValue.Name = "PublishMode";
669
670 HtmlPublishMode ePublishMode;
671 if (m_xPage2_Frames->get_active())
672 ePublishMode = PUBLISH_FRAMES;
673 else if (m_xPage2_SingleDocument->get_active())
674 ePublishMode = PUBLISH_SINGLE_DOCUMENT;
675 else if (m_xPage2_Kiosk->get_active())
676 ePublishMode = PUBLISH_KIOSK;
677 else if (m_xPage2_WebCast->get_active())
678 ePublishMode = PUBLISH_WEBCAST;
679 else
680 ePublishMode = PUBLISH_HTML;
681
682 aValue.Value <<= static_cast<sal_Int32>(ePublishMode);
683 aProps.push_back( aValue );
684
685 aValue.Name = "IsExportContentsPage";
686 aValue.Value <<= m_xPage2_Content->get_active();
687 aProps.push_back( aValue );
688
689 if(m_bImpress)
690 {
691 aValue.Name = "IsExportNotes";
692 aValue.Value <<= m_xPage2_Notes->get_active();
693 aProps.push_back( aValue );
694 }
695
696 if( m_xPage2_WebCast->get_active() )
697 {
698 aValue.Name = "WebCastScriptLanguage";
699 if( m_xPage2_ASP->get_active() )
700 aValue.Value <<= OUString( "asp" );
701 else
702 aValue.Value <<= OUString( "perl" );
703 aProps.push_back( aValue );
704
705 aValue.Name = "WebCastCGIURL";
706 aValue.Value <<= m_xPage2_CGI->get_text();
707 aProps.push_back( aValue );
708
709 aValue.Name = "WebCastTargetURL";
710 aValue.Value <<= m_xPage2_URL->get_text();
711 aProps.push_back( aValue );
712 }
713 aValue.Name = "IndexURL";
714 aValue.Value <<= m_xPage2_Index->get_text();
715 aProps.push_back( aValue );
716
717 if( m_xPage2_Kiosk->get_active() && m_xPage2_ChgAuto->get_active() )
718 {
719 aValue.Name = "KioskSlideDuration";
720 aValue.Value <<= static_cast<sal_uInt32>(m_xFormatter->GetTime().GetMSFromTime()) / 1000;
721 aProps.push_back( aValue );
722
723 aValue.Name = "KioskEndless";
724 aValue.Value <<= m_xPage2_Endless->get_active();
725 aProps.push_back( aValue );
726 }
727
728 // Page 3
729
730 aValue.Name = "Width";
731 sal_Int32 nTmpWidth = PUB_LOWRES_WIDTH;
732 if( m_xPage3_Resolution_2->get_active() )
733 nTmpWidth = PUB_MEDRES_WIDTH;
734 else if( m_xPage3_Resolution_3->get_active() )
735 nTmpWidth = PUB_HIGHRES_WIDTH;
736 else if (m_xPage3_Resolution_4->get_active())
737 nTmpWidth = PUB_FHDRES_WIDTH;
738
739 aValue.Value <<= nTmpWidth;
740 aProps.push_back( aValue );
741
742 aValue.Name = "Compression";
743 aValue.Value <<= m_xPage3_Quality->get_active_text();
744 aProps.push_back( aValue );
745
746 aValue.Name = "Format";
747 sal_Int32 nFormat;
748 if( m_xPage3_Png->get_active() )
749 nFormat = static_cast<sal_Int32>(FORMAT_PNG);
750 else if( m_xPage3_Gif->get_active() )
751 nFormat = static_cast<sal_Int32>(FORMAT_GIF);
752 else
753 nFormat = static_cast<sal_Int32>(FORMAT_JPG);
754 aValue.Value <<= nFormat;
755 aProps.push_back( aValue );
756
757 aValue.Name = "SlideSound";
758 aValue.Value <<= m_xPage3_SldSound->get_active();
759 aProps.push_back( aValue );
760
761 aValue.Name = "HiddenSlides";
762 aValue.Value <<= m_xPage3_HiddenSlides->get_active();
763 aProps.push_back( aValue );
764
765 // Page 4
766 aValue.Name = "Author";
767 aValue.Value <<= m_xPage4_Author->get_text();
768 aProps.push_back( aValue );
769
770 aValue.Name = "EMail";
771 aValue.Value <<= m_xPage4_Email->get_text();
772 aProps.push_back( aValue );
773
774 // try to guess protocol for user's homepage
775 INetURLObject aHomeURL( m_xPage4_WWW->get_text(),
776 INetProtocol::Http, // default proto is HTTP
778
779 aValue.Name = "HomepageURL";
780 aValue.Value <<= aHomeURL.GetMainURL( INetURLObject::DecodeMechanism::NONE );
781 aProps.push_back( aValue );
782
783 aValue.Name = "UserText";
784 aValue.Value <<= m_xPage4_Misc->get_text();
785 aProps.push_back( aValue );
786
787 if( m_bImpress )
788 {
789 aValue.Name = "EnableDownload";
790 aValue.Value <<= m_xPage4_Download->get_active();
791 aProps.push_back( aValue );
792 }
793
794 // Page 5
795 if( !m_xPage5_TextOnly->get_active() )
796 {
797 aValue.Name = "UseButtonSet";
798 aValue.Value <<= static_cast<sal_Int32>(m_xPage5_Buttons->GetSelectedItemId() - 1);
799 aProps.push_back( aValue );
800 }
801
802 // Page 6
803 if( m_xPage6_User->get_active() )
804 {
805 aValue.Name = "BackColor";
806 aValue.Value <<= m_aBackColor;
807 aProps.push_back( aValue );
808
809 aValue.Name = "TextColor";
810 aValue.Value <<= m_aTextColor;
811 aProps.push_back( aValue );
812
813 aValue.Name = "LinkColor";
814 aValue.Value <<= m_aLinkColor;
815 aProps.push_back( aValue );
816
817 aValue.Name = "VLinkColor";
818 aValue.Value <<= m_aVLinkColor;
819 aProps.push_back( aValue );
820
821 aValue.Name = "ALinkColor";
822 aValue.Value <<= m_aALinkColor;
823 aProps.push_back( aValue );
824 }
825
826 if( m_xPage6_DocColors->get_active() )
827 {
828 aValue.Name = "IsUseDocumentColors";
829 aValue.Value <<= true;
830 aProps.push_back( aValue );
831 }
832
833 rParams = comphelper::containerToSequence(aProps);
834}
835
836// Clickhandler for the radiobuttons of the design-selection
837IMPL_LINK( SdPublishingDlg, DesignHdl, weld::Toggleable&, rButton, void )
838{
839 if (!rButton.get_active())
840 return;
841
842 if (m_xPage1_NewDesign->get_active())
843 {
844 m_xPage1_NewDesign->set_active(true); // because of DesignDeleteHdl
845 m_xPage1_OldDesign->set_active(false);
846 m_xPage1_Designs->set_sensitive(false);
847 m_xPage1_DelDesign->set_sensitive(false);
848 m_pDesign = nullptr;
849
850 SdPublishingDesign aDefault;
851 SetDesign(&aDefault);
852 }
853 else
854 {
855 m_xPage1_NewDesign->set_active(false);
856 m_xPage1_Designs->set_sensitive(true);
857 m_xPage1_DelDesign->set_sensitive(true);
858
859 if (m_xPage1_Designs->get_selected_index() == -1)
860 m_xPage1_Designs->select(0);
861
862 const sal_Int32 nPos = m_xPage1_Designs->get_selected_index();
863 m_pDesign = &m_aDesignList[nPos];
864 DBG_ASSERT(m_pDesign, "No Design? That's not allowed (CL)");
865
866 if(m_pDesign)
867 SetDesign(m_pDesign);
868 }
869}
870
871// Clickhandler for the choice of one design
873{
874 const sal_Int32 nPos = m_xPage1_Designs->get_selected_index();
875 m_pDesign = &m_aDesignList[nPos];
876 DBG_ASSERT(m_pDesign, "No Design? That's not allowed (CL)");
877
878 if(m_pDesign)
879 SetDesign(m_pDesign);
880
881 UpdatePage();
882}
883
884// Clickhandler for the delete of one design
886{
887 const sal_Int32 nPos = m_xPage1_Designs->get_selected_index();
888
889 std::vector<SdPublishingDesign>::iterator iter = m_aDesignList.begin()+nPos;
890
891 DBG_ASSERT(iter != m_aDesignList.end(), "No Design? That's not allowed (CL)");
892
893 m_xPage1_Designs->remove(nPos);
894
895 if(m_pDesign == &(*iter))
896 DesignHdl(*m_xPage1_NewDesign);
897
898 m_aDesignList.erase(iter);
899
900 m_bDesignListDirty = true;
901
902 UpdatePage();
903}
904
905// Clickhandler for the other servertypes
906IMPL_LINK(SdPublishingDlg, WebServerHdl, weld::Toggleable&, rButton, void)
907{
908 if (!rButton.get_active())
909 return;
910
911 bool bASP = m_xPage2_ASP->get_active();
912 m_xPage2_ASP->set_sensitive( bASP );
913 m_xPage2_PERL->set_sensitive( !bASP );
914 UpdatePage();
915}
916
917// Clickhandler for the Radiobuttons of the graphicformat choice
918IMPL_LINK(SdPublishingDlg, GfxFormatHdl, weld::Toggleable&, rButton, void)
919{
920 if (!rButton.get_active())
921 return;
922
923 m_xPage3_Png->set_sensitive(m_xPage3_Png->get_active());
924 m_xPage3_Gif->set_sensitive(m_xPage3_Gif->get_active());
925 m_xPage3_Jpg->set_sensitive(m_xPage3_Jpg->get_active());
926 m_xPage3_Quality->set_sensitive(m_xPage3_Jpg->get_active());
927}
928
929// Clickhandler for the Radiobuttons Standard/Frames
931{
932 if (!rButton.get_active())
933 return;
934
935 UpdatePage();
936}
937
938// Clickhandler for the Checkbox of the Title page
940{
941 if(m_xPage2_Content->get_active())
942 {
943 if(!aAssistentFunc.IsEnabled(4))
944 {
945 aAssistentFunc.EnablePage(4);
946 UpdatePage();
947 }
948 }
949 else
950 {
951 if(aAssistentFunc.IsEnabled(4))
952 {
953 aAssistentFunc.DisablePage(4);
954 UpdatePage();
955 }
956 }
957}
958
959// Clickhandler for the Resolution Radiobuttons
960IMPL_LINK( SdPublishingDlg, ResolutionHdl, weld::Toggleable&, rButton, void )
961{
962 if (!rButton.get_active())
963 return;
964 m_xPage3_Resolution_1->set_sensitive(m_xPage3_Resolution_1->get_active());
965 m_xPage3_Resolution_2->set_sensitive(m_xPage3_Resolution_2->get_active());
966 m_xPage3_Resolution_3->set_sensitive(m_xPage3_Resolution_3->get_active());
967 m_xPage3_Resolution_4->set_sensitive(m_xPage3_Resolution_4->get_active());
968}
969
970// Clickhandler for the ValueSet with the bitmap-buttons
972{
973 // if one bitmap-button is chosen, then disable TextOnly
974 m_xPage5_TextOnly->set_active(false);
975}
976
977// Fill the SfxItemSet with the settings of the dialog
978IMPL_LINK( SdPublishingDlg, ColorHdl, weld::Button&, rButton, void)
979{
980 SvColorDialog aDlg;
981
982 if (&rButton == m_xPage6_Back.get())
983 {
984 aDlg.SetColor( m_aBackColor );
985 if(aDlg.Execute(m_xDialog.get()) == RET_OK )
986 m_aBackColor = aDlg.GetColor();
987 }
988 else if (&rButton == m_xPage6_Text.get())
989 {
990 aDlg.SetColor( m_aTextColor );
991 if(aDlg.Execute(m_xDialog.get()) == RET_OK )
992 m_aTextColor = aDlg.GetColor();
993 }
994 else if (&rButton == m_xPage6_Link.get())
995 {
996 aDlg.SetColor( m_aLinkColor );
997 if(aDlg.Execute(m_xDialog.get()) == RET_OK )
998 m_aLinkColor = aDlg.GetColor();
999 }
1000 else if (&rButton == m_xPage6_VLink.get())
1001 {
1002 aDlg.SetColor( m_aVLinkColor );
1003 if(aDlg.Execute(m_xDialog.get()) == RET_OK )
1004 m_aVLinkColor = aDlg.GetColor();
1005 }
1006 else if (&rButton == m_xPage6_ALink.get())
1007 {
1008 aDlg.SetColor( m_aALinkColor );
1009 if(aDlg.Execute(m_xDialog.get()) == RET_OK )
1010 m_aALinkColor = aDlg.GetColor();
1011 }
1012
1013 m_xPage6_User->set_active(true);
1014 m_xPage6_Preview->SetColors( m_aBackColor, m_aTextColor, m_aLinkColor,
1015 m_aVLinkColor, m_aALinkColor );
1016 m_xPage6_Preview->Invalidate();
1017}
1018
1019IMPL_LINK(SdPublishingDlg, SlideChgHdl, weld::Toggleable&, rButton, void)
1020{
1021 if (!rButton.get_active())
1022 return;
1023 UpdatePage();
1024}
1025
1026// Clickhandler for the Ok Button
1028{
1029 //End
1030 SdPublishingDesign aDesign;
1031 GetDesign(&aDesign);
1032
1033 bool bSave = false;
1034
1035 if(m_xPage1_OldDesign->get_active() && m_pDesign)
1036 {
1037 // are there changes?
1038 if(!(aDesign == *m_pDesign))
1039 bSave = true;
1040 }
1041 else
1042 {
1043 SdPublishingDesign aDefaultDesign;
1044 if(!(aDefaultDesign == aDesign))
1045 bSave = true;
1046 }
1047
1048 if(bSave)
1049 {
1050 OUString aName;
1051 if(m_pDesign)
1052 aName = m_pDesign->m_aDesignName;
1053
1054 bool bRetry;
1055 do
1056 {
1057 bRetry = false;
1058
1059 SdDesignNameDlg aDlg(m_xDialog.get(), aName);
1060
1061 if (aDlg.run() == RET_OK)
1062 {
1063 aDesign.m_aDesignName = aDlg.GetDesignName();
1064
1065 auto iter = std::find_if(m_aDesignList.begin(), m_aDesignList.end(),
1066 [&aDesign](const SdPublishingDesign& rDesign) { return rDesign.m_aDesignName == aDesign.m_aDesignName; });
1067
1068 if (iter != m_aDesignList.end())
1069 {
1070 std::unique_ptr<weld::MessageDialog> xErrorBox(Application::CreateMessageDialog(m_xDialog.get(),
1071 VclMessageType::Error, VclButtonsType::YesNo,
1072 SdResId(STR_PUBDLG_SAMENAME)));
1073 bRetry = xErrorBox->run() == RET_NO;
1074
1075 if(!bRetry)
1076 m_aDesignList.erase(iter);
1077 }
1078
1079 if(!bRetry)
1080 {
1081 m_aDesignList.push_back(aDesign);
1082 m_bDesignListDirty = true;
1083 }
1084 }
1085 }
1086 while(bRetry);
1087 }
1088
1089 if(m_bDesignListDirty)
1090 Save();
1091
1092 m_xDialog->response(RET_OK);
1093}
1094
1095// Refresh the dialogs when changing from pages
1097{
1098 int nPage = aAssistentFunc.GetCurrentPage();
1099 m_xDialog->set_help_id(aPageHelpIds[nPage-1]);
1100
1101 UpdatePage();
1102
1103 if (m_xNextPageButton->get_sensitive())
1104 m_xNextPageButton->grab_focus();
1105 else
1106 m_xFinishButton->grab_focus();
1107}
1108
1110{
1111 m_xNextPageButton->set_sensitive(!aAssistentFunc.IsLastPage());
1112 m_xLastPageButton->set_sensitive(!aAssistentFunc.IsFirstPage());
1113
1114 int nPage = aAssistentFunc.GetCurrentPage();
1115
1116 switch( nPage )
1117 {
1118 case 1:
1119 if(m_xPage1_NewDesign->get_active())
1120 {
1121 m_xPage1_Designs->set_sensitive(false);
1122 m_xPage1_DelDesign->set_sensitive(false);
1123 }
1124
1125 if(m_aDesignList.empty())
1126 m_xPage1_OldDesign->set_sensitive(false);
1127 break;
1128 case 2:
1129 m_xPage2_Frames_FB->set_visible(m_xPage2_Frames->get_active());
1130 m_xPage2_Standard_FB->set_visible(m_xPage2_Standard->get_active());
1131 m_xPage2_Kiosk_FB->set_visible(m_xPage2_Kiosk->get_active());
1132 m_xPage2_WebCast_FB->set_visible(m_xPage2_WebCast->get_active());
1133
1134 if( m_xPage2_WebCast->get_active() )
1135 {
1136 m_xPage2Frame4->show();
1137 m_xPage2_Title_WebCast->show();
1138 m_xPage2_ASP->show();
1139 m_xPage2_PERL->show();
1140 m_xPage2_URL_txt->show();
1141 m_xPage2_URL->show();
1142 m_xPage2_CGI_txt->show();
1143 m_xPage2_CGI->show();
1144 m_xPage2_Index_txt->show();
1145 m_xPage2_Index->show();
1146
1147 bool bPerl = m_xPage2_PERL->get_active();
1148 m_xPage2_Index->set_sensitive(bPerl);
1149 m_xPage2_Index_txt->set_sensitive(bPerl);
1150 m_xPage2_URL_txt->set_sensitive(bPerl);
1151 m_xPage2_URL->set_sensitive(bPerl);
1152 m_xPage2_CGI_txt->set_sensitive(bPerl);
1153 m_xPage2_CGI->set_sensitive(bPerl);
1154 }
1155 else
1156 {
1157 m_xPage2Frame4->hide();
1158 m_xPage2_Title_WebCast->hide();
1159 m_xPage2_ASP->hide();
1160 m_xPage2_PERL->hide();
1161 m_xPage2_URL_txt->hide();
1162 m_xPage2_URL->hide();
1163 m_xPage2_CGI_txt->hide();
1164 m_xPage2_CGI->hide();
1165 m_xPage2_Index->hide();
1166 m_xPage2_Index_txt->hide();
1167 }
1168
1169 if( m_xPage2_Kiosk->get_active() )
1170 {
1171 m_xPage2Frame3->show();
1172 m_xPage2_Title_Kiosk->show();
1173 m_xPage2_ChgDefault->show();
1174 m_xPage2_ChgAuto->show();
1175 m_xPage2_Duration_txt->show();
1176 m_xPage2_Duration->show();
1177 m_xPage2_Endless->show();
1178 bool bAuto = m_xPage2_ChgAuto->get_active();
1179 m_xPage2_Duration->set_sensitive(bAuto);
1180 m_xPage2_Endless->set_sensitive(bAuto);
1181 }
1182 else
1183 {
1184 m_xPage2Frame3->hide();
1185 m_xPage2_Title_Kiosk->hide();
1186 m_xPage2_ChgDefault->hide();
1187 m_xPage2_ChgAuto->hide();
1188 m_xPage2_Duration->hide();
1189 m_xPage2_Duration_txt->hide();
1190 m_xPage2_Endless->hide();
1191 }
1192
1193 if( m_xPage2_Standard->get_active() || m_xPage2_Frames->get_active() )
1194 {
1195 m_xPage2Frame2->show();
1196 m_xPage2_Title_Html->show();
1197 m_xPage2_Content->show();
1198 if(m_bImpress)
1199 m_xPage2_Notes->show();
1200 }
1201 else
1202 {
1203 m_xPage2Frame2->hide();
1204 m_xPage2_Title_Html->hide();
1205 m_xPage2_Content->hide();
1206 if(m_bImpress)
1207 m_xPage2_Notes->hide();
1208 }
1209 break;
1210 case 3:
1211 if( m_xPage2_Kiosk->get_active() || m_xPage2_WebCast->get_active() )
1212 m_xNextPageButton->set_sensitive(false);
1213
1214 if( m_xPage2_WebCast->get_active() )
1215 m_xPage3_SldSound->set_sensitive(false);
1216
1217 m_xPage3_Quality->set_sensitive(m_xPage3_Jpg->get_active());
1218
1219 break;
1220 case 5:
1221 if( m_bButtonsDirty )
1223 break;
1224 }
1225}
1226
1231{
1232 if (!m_xButtonSet)
1233 return;
1234
1235 const int nButtonCount = 8;
1236 static const char *pButtonNames[nButtonCount] =
1237 {
1238 "first.png",
1239 "left.png",
1240 "right.png",
1241 "last.png",
1242 "home.png",
1243 "text.png",
1244 "expand.png",
1245 "collapse.png",
1246 };
1247
1248 std::vector< OUString > aButtonNames;
1249 for(const char * p : pButtonNames)
1250 aButtonNames.push_back( OUString::createFromAscii( p ) );
1251
1252 int nSetCount = m_xButtonSet->getCount();
1253
1254 int nHeight = 32;
1255 Image aImage;
1256 for( int nSet = 0; nSet < nSetCount; ++nSet )
1257 {
1258 if( m_xButtonSet->getPreview( nSet, aButtonNames, aImage ) )
1259 {
1260 m_xPage5_Buttons->InsertItem( static_cast<sal_uInt16>(nSet)+1, aImage );
1261 if( nHeight < aImage.GetSizePixel().Height() )
1262 nHeight = aImage.GetSizePixel().Height();
1263 }
1264 }
1265
1266 m_xPage5_Buttons->SetItemHeight( nHeight );
1267 m_bButtonsDirty = false;
1268}
1269
1270// Clickhandler for the Forward Button
1272{
1273 aAssistentFunc.NextPage();
1274 ChangePage();
1275}
1276
1277// Sets the Controls in the dialog to the settings in the design
1279{
1280 if(!pDesign)
1281 return;
1282
1283 m_xPage2_Standard->set_sensitive(pDesign->m_eMode == PUBLISH_HTML);
1284 m_xPage2_Frames->set_sensitive(pDesign->m_eMode == PUBLISH_FRAMES);
1285 m_xPage2_Kiosk->set_sensitive(pDesign->m_eMode == PUBLISH_KIOSK );
1286 m_xPage2_WebCast->set_sensitive(pDesign->m_eMode == PUBLISH_WEBCAST );
1287
1288 m_xPage2_Content->set_sensitive(pDesign->m_bContentPage);
1289 if(pDesign->m_bContentPage)
1291 else
1293
1294 if(m_bImpress)
1295 m_xPage2_Notes->set_sensitive(pDesign->m_bNotes);
1296
1297 m_xPage2_ASP->set_sensitive(pDesign->m_eScript == SCRIPT_ASP);
1298 m_xPage2_PERL->set_sensitive(pDesign->m_eScript == SCRIPT_PERL);
1299 m_xPage2_CGI->set_text(pDesign->m_aCGI);
1300 m_xPage2_URL->set_text(pDesign->m_aURL);
1301
1302 m_xPage2_ChgDefault->set_sensitive( !pDesign->m_bAutoSlide );
1303 m_xPage2_ChgAuto->set_sensitive( pDesign->m_bAutoSlide );
1304
1306 aTime.MakeTimeFromMS( pDesign->m_nSlideDuration * 1000 );
1307 m_xFormatter->SetTime(aTime);
1308
1309 m_xPage2_Endless->set_sensitive( pDesign->m_bEndless );
1310
1311 m_xPage3_Png->set_sensitive(pDesign->m_eFormat == FORMAT_PNG);
1312 m_xPage3_Gif->set_sensitive(pDesign->m_eFormat == FORMAT_GIF);
1313 m_xPage3_Jpg->set_sensitive(pDesign->m_eFormat == FORMAT_JPG);
1314 m_xPage3_Quality->set_sensitive(pDesign->m_eFormat == FORMAT_JPG);
1315
1316 m_xPage3_Quality->set_entry_text(pDesign->m_aCompression);
1317 m_xPage3_Resolution_1->set_sensitive(pDesign->m_nResolution == PUB_LOWRES_WIDTH);
1318 m_xPage3_Resolution_2->set_sensitive(pDesign->m_nResolution == PUB_MEDRES_WIDTH);
1319 m_xPage3_Resolution_3->set_sensitive(pDesign->m_nResolution == PUB_HIGHRES_WIDTH);
1320 m_xPage3_Resolution_4->set_sensitive(pDesign->m_nResolution == PUB_FHDRES_WIDTH);
1321
1322 m_xPage3_SldSound->set_sensitive( pDesign->m_bSlideSound );
1323 m_xPage3_HiddenSlides->set_sensitive( pDesign->m_bHiddenSlides );
1324
1325 m_xPage4_Author->set_text(pDesign->m_aAuthor);
1326 m_xPage4_Email->set_text(pDesign->m_aEMail);
1327 m_xPage4_WWW->set_text(pDesign->m_aWWW);
1328 m_xPage4_Misc->set_text(pDesign->m_aMisc);
1329 if(m_bImpress)
1330 m_xPage4_Download->set_sensitive(pDesign->m_bDownload);
1331
1332 m_xPage5_TextOnly->set_sensitive(pDesign->m_nButtonThema == -1);
1333 if(pDesign->m_nButtonThema != -1)
1334 {
1335 if(m_bButtonsDirty)
1337 m_xPage5_Buttons->SelectItem(pDesign->m_nButtonThema + 1);
1338 }
1339 else
1340 m_xPage5_Buttons->SetNoSelection();
1341
1342 m_xPage6_User->set_sensitive(pDesign->m_bUserAttr);
1343 m_aBackColor = pDesign->m_aBackColor;
1344 m_aTextColor = pDesign->m_aTextColor;
1345 m_aLinkColor = pDesign->m_aLinkColor;
1346 m_aVLinkColor = pDesign->m_aVLinkColor;
1347 m_aALinkColor = pDesign->m_aALinkColor;
1348
1349 m_xPage6_DocColors->set_sensitive(pDesign->m_bUseColor);
1350
1353 m_xPage6_Preview->Invalidate();
1354
1355 UpdatePage();
1356}
1357
1358// Transfer the status of the Design Dialog Controls
1360{
1361 if(!pDesign)
1362 return;
1363
1364 pDesign->m_eMode = m_xPage2_Standard->get_active()?PUBLISH_HTML:
1365 m_xPage2_Frames->get_active()?PUBLISH_FRAMES:
1366 m_xPage2_Kiosk->get_active()?PUBLISH_KIOSK:
1368
1369 pDesign->m_bContentPage = m_xPage2_Content->get_active();
1370 if(m_bImpress)
1371 pDesign->m_bNotes = m_xPage2_Notes->get_active();
1372
1373 if( m_xPage3_Gif->get_active() )
1374 pDesign->m_eFormat = FORMAT_GIF;
1375 else if( m_xPage3_Jpg->get_active() )
1376 pDesign->m_eFormat = FORMAT_JPG;
1377 else
1378 pDesign->m_eFormat = FORMAT_PNG;
1379
1380 pDesign->m_aCompression = m_xPage3_Quality->get_active_text();
1381
1382 if (m_xPage3_Resolution_1->get_active())
1384 else if (m_xPage3_Resolution_2->get_active())
1386 else if (m_xPage3_Resolution_3->get_active())
1388 else
1390
1391 pDesign->m_bSlideSound = m_xPage3_SldSound->get_active();
1392 pDesign->m_bHiddenSlides = m_xPage3_HiddenSlides->get_active();
1393
1394 pDesign->m_aAuthor = m_xPage4_Author->get_text();
1395 pDesign->m_aEMail = m_xPage4_Email->get_text();
1396 pDesign->m_aWWW = m_xPage4_WWW->get_text();
1397 pDesign->m_aMisc = m_xPage4_Misc->get_text();
1398 pDesign->m_bDownload = m_bImpress && m_xPage4_Download->get_active();
1399
1400 if(m_xPage5_TextOnly->get_active())
1401 pDesign->m_nButtonThema = -1;
1402 else
1403 pDesign->m_nButtonThema = m_xPage5_Buttons->GetSelectedItemId() - 1;
1404
1405 pDesign->m_bUserAttr = m_xPage6_User->get_active();
1406 pDesign->m_aBackColor = m_aBackColor;
1407 pDesign->m_aTextColor = m_aTextColor;
1408 pDesign->m_aLinkColor = m_aLinkColor;
1409 pDesign->m_aVLinkColor = m_aVLinkColor;
1410 pDesign->m_aALinkColor = m_aALinkColor;
1411 pDesign->m_bUseColor = m_xPage6_DocColors->get_active();
1412
1413 pDesign->m_eScript = m_xPage2_ASP->get_active()?SCRIPT_ASP:SCRIPT_PERL;
1414 pDesign->m_aCGI = m_xPage2_CGI->get_text();
1415 pDesign->m_aURL = m_xPage2_URL->get_text();
1416
1417 pDesign->m_bAutoSlide = m_xPage2_ChgAuto->get_active();
1418 pDesign->m_nSlideDuration = static_cast<sal_uInt32>(m_xFormatter->GetTime().GetMSFromTime()) / 1000;
1419 pDesign->m_bEndless = m_xPage2_Endless->get_active();
1420}
1421
1422// Clickhandler for the back Button
1424{
1425 aAssistentFunc.PreviousPage();
1426 ChangePage();
1427}
1428
1429// Load Designs
1431{
1432 m_bDesignListDirty = false;
1433
1434 INetURLObject aURL( SvtPathOptions().GetUserConfigPath() );
1435 aURL.Append( u"designs.sod" );
1436
1437 // check if file exists, SfxMedium shows an errorbox else
1438 {
1439 std::unique_ptr<SvStream> pIStm = ::utl::UcbStreamHelper::CreateStream( aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ), StreamMode::READ );
1440
1441 bool bOk = pIStm && ( pIStm->GetError() == ERRCODE_NONE);
1442
1443 if( !bOk )
1444 return;
1445 }
1446
1447 SfxMedium aMedium( aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ), StreamMode::READ | StreamMode::NOCREATE );
1448
1449 SvStream* pStream = aMedium.GetInStream();
1450
1451 if( !pStream )
1452 return;
1453
1454 sal_uInt16 aCheck;
1455 pStream->ReadUInt16( aCheck );
1456
1457 if(aCheck != nMagic)
1458 return;
1459
1460 SdIOCompat aIO(*pStream, StreamMode::READ);
1461
1462 sal_uInt16 nDesigns(0);
1463 pStream->ReadUInt16(nDesigns);
1464
1465 // there has to at least be a sal_uInt16 header in each design
1466 const size_t nMaxRecords = pStream->remainingSize() / sizeof(sal_uInt16);
1467 if (nDesigns > nMaxRecords)
1468 {
1469 SAL_WARN("sd", "Parsing error: " << nMaxRecords <<
1470 " max possible entries, but " << nDesigns << " claimed, truncating");
1471 nDesigns = nMaxRecords;
1472 }
1473
1474 for( sal_uInt16 nIndex = 0;
1475 pStream->GetError() == ERRCODE_NONE && nIndex < nDesigns;
1476 nIndex++ )
1477 {
1478 SdPublishingDesign aDesign;
1479 *pStream >> aDesign;
1480
1481 m_aDesignList.push_back(aDesign);
1482 }
1483}
1484
1485// Save Designs
1487{
1488 INetURLObject aURL( SvtPathOptions().GetUserConfigPath() );
1489 aURL.Append( u"designs.sod" );
1490 SfxMedium aMedium( aURL.GetMainURL( INetURLObject::DecodeMechanism::NONE ), StreamMode::WRITE | StreamMode::TRUNC );
1491
1492 SvStream* pStream = aMedium.GetOutStream();
1493
1494 if( !pStream )
1495 return false;
1496
1497 pStream->WriteUInt16( nMagic );
1498
1499 // Destroys the SdIOCompat before the Stream is being distributed
1500 {
1501 SdIOCompat aIO(*pStream, StreamMode::WRITE, 0);
1502
1503 sal_uInt16 nDesigns = static_cast<sal_uInt16>(m_aDesignList.size());
1504 pStream->WriteUInt16( nDesigns );
1505
1506 for( sal_uInt16 nIndex = 0;
1507 pStream->GetError() == ERRCODE_NONE && nIndex < nDesigns;
1508 nIndex++ )
1510 }
1511
1512 aMedium.Close();
1513 aMedium.Commit();
1514
1515 return( aMedium.GetError() == ERRCODE_NONE );
1516}
1517
1518// SdDesignNameDlg Methods
1519SdDesignNameDlg::SdDesignNameDlg(weld::Window* pWindow, const OUString& rName)
1520 : GenericDialogController(pWindow, "modules/sdraw/ui/namedesign.ui", "NameDesignDialog")
1521 , m_xEdit(m_xBuilder->weld_entry("entry"))
1522 , m_xBtnOK(m_xBuilder->weld_button("ok"))
1523{
1524 m_xEdit->connect_changed(LINK(this, SdDesignNameDlg, ModifyHdl ));
1525 m_xEdit->set_text(rName);
1526 m_xBtnOK->set_sensitive(!rName.isEmpty());
1527}
1528
1529OUString SdDesignNameDlg::GetDesignName() const
1530{
1531 return m_xEdit->get_text();
1532}
1533
1534IMPL_LINK_NOARG(SdDesignNameDlg, ModifyHdl, weld::Entry&, void)
1535{
1536 m_xBtnOK->set_sensitive(!m_xEdit->get_text().isEmpty());
1537}
1538
1539/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Reference< XExecutableDialog > m_xDialog
static weld::MessageDialog * CreateMessageDialog(weld::Widget *pParent, VclMessageType eMessageType, VclButtonsType eButtonType, const OUString &rPrimaryMessage, const ILibreOfficeKitNotifier *pNotifier=nullptr)
bool IsLastPage() const
Definition: assclass.cxx:107
bool IsFirstPage() const
Definition: assclass.cxx:119
void EnablePage(int nPage)
Definition: assclass.cxx:138
int GetCurrentPage() const
Definition: assclass.hxx:65
bool InsertControl(int nDestPage, weld::Widget *pUsedControl)
adds a control to the specified page
Definition: assclass.cxx:37
bool GotoPage(const int nPageToGo)
Definition: assclass.cxx:78
void DisablePage(int nPage)
Definition: assclass.cxx:148
sal_Int32 ReadInt32(const OUString &rKey, sal_Int32 nDefault)
OUString GetMainURL(DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
Size GetSizePixel() const
HtmlPublishMode m_eMode
Definition: pubdlg.cxx:81
PublishingScript m_eScript
Definition: pubdlg.cxx:84
PublishingFormat m_eFormat
Definition: pubdlg.cxx:100
OUString m_aAuthor
Definition: pubdlg.cxx:105
sal_Int16 m_nButtonThema
Definition: pubdlg.cxx:113
OUString m_aCompression
Definition: pubdlg.cxx:99
OUString m_aDesignName
Definition: pubdlg.cxx:79
friend SvStream & operator>>(SvStream &rIn, SdPublishingDesign &rDesign)
Definition: pubdlg.cxx:230
OUString m_aWWW
Definition: pubdlg.cxx:107
sal_uInt32 m_nSlideDuration
Definition: pubdlg.cxx:90
OUString m_aEMail
Definition: pubdlg.cxx:106
OUString m_aCGI
Definition: pubdlg.cxx:85
sal_uInt16 m_nResolution
Definition: pubdlg.cxx:98
OUString m_aURL
Definition: pubdlg.cxx:86
friend SvStream & WriteSdPublishingDesign(SvStream &rOut, const SdPublishingDesign &rDesign)
Definition: pubdlg.cxx:285
OUString m_aMisc
Definition: pubdlg.cxx:108
bool operator==(const SdPublishingDesign &rDesign) const
Definition: pubdlg.cxx:168
std::unique_ptr< weld::CheckButton > m_xPage2_Endless
Definition: pubdlg.hxx:97
std::unique_ptr< weld::CheckButton > m_xPage3_HiddenSlides
Definition: pubdlg.hxx:114
std::unique_ptr< weld::RadioButton > m_xPage2_ChgDefault
Definition: pubdlg.hxx:92
std::unique_ptr< weld::Container > m_xPage2Frame4
Definition: pubdlg.hxx:66
std::unique_ptr< weld::RadioButton > m_xPage2_PERL
Definition: pubdlg.hxx:84
SdPublishingDlg(weld::Window *pWindow, DocumentType eDocType)
Definition: pubdlg.cxx:357
Color m_aVLinkColor
Definition: pubdlg.hxx:166
std::unique_ptr< weld::ComboBox > m_xPage3_Quality
Definition: pubdlg.hxx:106
std::unique_ptr< weld::RadioButton > m_xPage2_ChgAuto
Definition: pubdlg.hxx:93
std::unique_ptr< weld::Label > m_xPage2_CGI_txt
Definition: pubdlg.hxx:87
std::unique_ptr< weld::Label > m_xPage2_Duration_txt
Definition: pubdlg.hxx:94
std::unique_ptr< weld::Label > m_xPage2_Title_Html
Definition: pubdlg.hxx:78
std::unique_ptr< weld::RadioButton > m_xPage3_Jpg
Definition: pubdlg.hxx:104
std::unique_ptr< weld::Button > m_xFinishButton
Definition: pubdlg.hxx:155
std::unique_ptr< weld::RadioButton > m_xPage3_Resolution_1
Definition: pubdlg.hxx:108
std::unique_ptr< weld::Label > m_xPage4_Email_txt
Definition: pubdlg.hxx:121
std::unique_ptr< weld::Label > m_xPage4_WWW_txt
Definition: pubdlg.hxx:123
std::unique_ptr< weld::Label > m_xPage1_Desc
Definition: pubdlg.hxx:60
std::unique_ptr< weld::Label > m_xPage4_Title1
Definition: pubdlg.hxx:118
std::unique_ptr< weld::CustomWeld > m_xPage5_ButtonsWnd
Definition: pubdlg.hxx:134
std::unique_ptr< weld::RadioButton > m_xPage1_OldDesign
Definition: pubdlg.hxx:57
Color m_aBackColor
Definition: pubdlg.hxx:165
std::unique_ptr< weld::Label > m_xPage1_Title
Definition: pubdlg.hxx:55
std::unique_ptr< weld::Container > m_xPage4
Definition: pubdlg.hxx:117
void UpdatePage()
Definition: pubdlg.cxx:1109
std::unique_ptr< weld::Entry > m_xPage4_Author
Definition: pubdlg.hxx:120
Color m_aLinkColor
Definition: pubdlg.hxx:165
std::unique_ptr< weld::TimeFormatter > m_xFormatter
Definition: pubdlg.hxx:96
std::unique_ptr< weld::Button > m_xNextPageButton
Definition: pubdlg.hxx:154
std::unique_ptr< weld::Container > m_xPage1
Definition: pubdlg.hxx:54
std::unique_ptr< weld::TreeView > m_xPage1_Designs
Definition: pubdlg.hxx:58
std::unique_ptr< weld::Entry > m_xPage2_URL
Definition: pubdlg.hxx:86
std::unique_ptr< weld::Button > m_xPage6_Text
Definition: pubdlg.hxx:142
std::unique_ptr< weld::RadioButton > m_xPage2_WebCast
Definition: pubdlg.hxx:72
std::unique_ptr< weld::CheckButton > m_xPage4_Download
Definition: pubdlg.hxx:127
void ChangePage()
Definition: pubdlg.cxx:1096
std::unique_ptr< weld::Button > m_xLastPageButton
Definition: pubdlg.hxx:153
std::unique_ptr< weld::CheckButton > m_xPage3_SldSound
Definition: pubdlg.hxx:113
Color m_aALinkColor
Definition: pubdlg.hxx:166
bool m_bDesignListDirty
Definition: pubdlg.hxx:172
std::unique_ptr< weld::RadioButton > m_xPage6_DocColors
Definition: pubdlg.hxx:146
std::unique_ptr< weld::FormattedSpinButton > m_xPage2_Duration
Definition: pubdlg.hxx:95
void CreatePages()
Definition: pubdlg.cxx:472
std::unique_ptr< weld::Container > m_xPage6
Definition: pubdlg.hxx:137
std::unique_ptr< weld::Entry > m_xPage2_CGI
Definition: pubdlg.hxx:88
std::unique_ptr< weld::Image > m_xPage2_WebCast_FB
Definition: pubdlg.hxx:76
std::unique_ptr< weld::RadioButton > m_xPage6_Default
Definition: pubdlg.hxx:139
std::unique_ptr< weld::Label > m_xPage4_Title2
Definition: pubdlg.hxx:125
std::unique_ptr< weld::Label > m_xPage3_Title3
Definition: pubdlg.hxx:112
std::unique_ptr< weld::Container > m_xPage3
Definition: pubdlg.hxx:100
std::unique_ptr< weld::Container > m_xPage2Frame3
Definition: pubdlg.hxx:65
void GetDesign(SdPublishingDesign *pDesign)
Definition: pubdlg.cxx:1359
std::unique_ptr< weld::Container > m_xPage5
Definition: pubdlg.hxx:130
std::unique_ptr< weld::RadioButton > m_xPage1_NewDesign
Definition: pubdlg.hxx:56
std::unique_ptr< weld::RadioButton > m_xPage2_Kiosk
Definition: pubdlg.hxx:71
std::unique_ptr< weld::RadioButton > m_xPage3_Gif
Definition: pubdlg.hxx:103
std::unique_ptr< ValueSet > m_xPage5_Buttons
Definition: pubdlg.hxx:133
std::unique_ptr< weld::Label > m_xPage3_Quality_txt
Definition: pubdlg.hxx:105
std::unique_ptr< weld::Button > m_xPage6_ALink
Definition: pubdlg.hxx:145
Color m_aTextColor
Definition: pubdlg.hxx:165
std::unique_ptr< weld::RadioButton > m_xPage3_Png
Definition: pubdlg.hxx:102
std::unique_ptr< weld::TextView > m_xPage4_Misc
Definition: pubdlg.hxx:126
bool m_bButtonsDirty
Definition: pubdlg.hxx:160
std::unique_ptr< weld::RadioButton > m_xPage2_SingleDocument
Definition: pubdlg.hxx:70
std::unique_ptr< weld::Container > m_xPage2
Definition: pubdlg.hxx:63
std::unique_ptr< weld::Entry > m_xPage4_Email
Definition: pubdlg.hxx:122
std::unique_ptr< weld::CheckButton > m_xPage5_TextOnly
Definition: pubdlg.hxx:132
std::unique_ptr< weld::Label > m_xPage5_Title
Definition: pubdlg.hxx:131
std::unique_ptr< weld::Label > m_xPage2_Index_txt
Definition: pubdlg.hxx:89
std::unique_ptr< weld::Label > m_xPage2_Title_Kiosk
Definition: pubdlg.hxx:91
void SetDefaults()
Definition: pubdlg.cxx:650
std::unique_ptr< weld::CustomWeld > m_xPage6_PreviewWnd
Definition: pubdlg.hxx:148
std::unique_ptr< ButtonSet > m_xButtonSet
Definition: pubdlg.hxx:150
void GetParameterSequence(css::uno::Sequence< css::beans::PropertyValue > &rParams)
Definition: pubdlg.cxx:661
std::unique_ptr< weld::Label > m_xPage6_Title
Definition: pubdlg.hxx:138
std::unique_ptr< weld::RadioButton > m_xPage3_Resolution_4
Definition: pubdlg.hxx:111
std::unique_ptr< weld::RadioButton > m_xPage6_User
Definition: pubdlg.hxx:140
std::unique_ptr< weld::Label > m_xPage2_URL_txt
Definition: pubdlg.hxx:85
std::unique_ptr< weld::RadioButton > m_xPage3_Resolution_3
Definition: pubdlg.hxx:110
std::unique_ptr< weld::Container > m_xPage2Frame2
Definition: pubdlg.hxx:64
std::unique_ptr< weld::Entry > m_xPage4_WWW
Definition: pubdlg.hxx:124
std::unique_ptr< weld::CheckButton > m_xPage2_Notes
Definition: pubdlg.hxx:80
std::unique_ptr< weld::Image > m_xPage2_Frames_FB
Definition: pubdlg.hxx:74
std::unique_ptr< weld::Button > m_xPage1_DelDesign
Definition: pubdlg.hxx:59
std::unique_ptr< weld::Label > m_xPage2_Title_WebCast
Definition: pubdlg.hxx:82
std::unique_ptr< weld::RadioButton > m_xPage2_Frames
Definition: pubdlg.hxx:69
std::unique_ptr< weld::RadioButton > m_xPage2_ASP
Definition: pubdlg.hxx:83
std::unique_ptr< weld::Image > m_xPage2_Kiosk_FB
Definition: pubdlg.hxx:75
std::unique_ptr< weld::Label > m_xPage2_Title
Definition: pubdlg.hxx:67
virtual ~SdPublishingDlg() override
Definition: pubdlg.cxx:467
void SetDesign(SdPublishingDesign const *pDesign)
Definition: pubdlg.cxx:1278
std::unique_ptr< weld::Entry > m_xPage2_Index
Definition: pubdlg.hxx:90
void LoadPreviewButtons()
loads the html buttons from the button sets, creates a preview and fills the itemset for page 5
Definition: pubdlg.cxx:1230
std::unique_ptr< weld::RadioButton > m_xPage2_Standard
Definition: pubdlg.hxx:68
std::unique_ptr< SdHtmlAttrPreview > m_xPage6_Preview
Definition: pubdlg.hxx:147
std::unique_ptr< weld::RadioButton > m_xPage3_Resolution_2
Definition: pubdlg.hxx:109
std::unique_ptr< weld::Button > m_xPage6_Link
Definition: pubdlg.hxx:143
Assistent aAssistentFunc
Definition: pubdlg.hxx:157
std::unique_ptr< weld::Button > m_xPage6_VLink
Definition: pubdlg.hxx:144
std::unique_ptr< weld::Image > m_xPage2_Standard_FB
Definition: pubdlg.hxx:73
std::vector< SdPublishingDesign > m_aDesignList
Definition: pubdlg.hxx:171
std::unique_ptr< weld::Label > m_xPage4_Author_txt
Definition: pubdlg.hxx:119
std::unique_ptr< weld::Button > m_xPage6_Back
Definition: pubdlg.hxx:141
std::unique_ptr< weld::Label > m_xPage3_Title2
Definition: pubdlg.hxx:107
std::unique_ptr< weld::Label > m_xPage3_Title1
Definition: pubdlg.hxx:101
std::unique_ptr< weld::CheckButton > m_xPage2_Content
Definition: pubdlg.hxx:79
void Close(bool bInDestruction=false)
ErrCode GetError() const
SvStream * GetOutStream()
SvStream * GetInStream()
bool Commit()
constexpr tools::Long Height() const
constexpr tools::Long Width() const
const Color & GetColor() const
short Execute(weld::Window *pParent)
void SetColor(const Color &rColor)
SvStream & ReadCharAsBool(bool &rBool)
SvStream & ReadInt16(sal_Int16 &rInt16)
SvStream & WriteBool(bool b)
SvStream & WriteInt16(sal_Int16 nInt16)
SvStream & WriteUInt16(sal_uInt16 nUInt16)
SvStream & WriteUInt32(sal_uInt32 nUInt32)
SvStream & ReadUInt32(sal_uInt32 &rUInt32)
ErrCode GetError() const
SvStream & ReadUInt16(sal_uInt16 &rUInt16)
sal_uInt64 remainingSize()
OUString GetFirstName() const
OUString GetEmail() const
OUString GetLastName() const
void writeColor(const Color &rColor)
void readColor(Color &rColor)
void MakeTimeFromMS(sal_Int32 nMS)
static std::unique_ptr< SvStream > CreateStream(const OUString &rFileName, StreamMode eOpenMode, css::uno::Reference< css::awt::XWindow > xParentWin=nullptr)
std::shared_ptr< weld::Dialog > m_xDialog
std::unique_ptr< weld::Builder > m_xBuilder
constexpr ::Color COL_GRAY(0x80, 0x80, 0x80)
constexpr ::Color COL_WHITE(0xFF, 0xFF, 0xFF)
constexpr ::Color COL_LIGHTGRAY(0xC0, 0xC0, 0xC0)
constexpr ::Color COL_BLUE(0x00, 0x00, 0x80)
constexpr ::Color COL_BLACK(0x00, 0x00, 0x00)
#define DBG_ASSERT(sCon, aError)
URL aURL
DECL_LINK(CheckNameHdl, SvxNameDialog &, bool)
float u
#define ERRCODE_NONE
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE6
Definition: helpids.h:35
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE1
Definition: helpids.h:30
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE5
Definition: helpids.h:34
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE3
Definition: helpids.h:32
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE2
Definition: helpids.h:31
constexpr OUStringLiteral HID_SD_HTMLEXPORT_PAGE4
Definition: helpids.h:33
const char *const pButtonNames[]
Definition: htmlex.cxx:93
#define PUB_LOWRES_WIDTH
Definition: htmlex.hxx:41
#define PUB_FHDRES_WIDTH
Definition: htmlex.hxx:44
#define PUB_HIGHRES_WIDTH
Definition: htmlex.hxx:43
#define PUB_MEDRES_WIDTH
Definition: htmlex.hxx:42
HtmlPublishMode
@ PUBLISH_KIOSK
@ PUBLISH_FRAMES
@ PUBLISH_HTML
@ PUBLISH_WEBCAST
@ PUBLISH_SINGLE_DOCUMENT
sal_Int32 nIndex
OUString aName
void * p
sal_uInt16 nPos
#define SAL_WARN(area, stream)
css::uno::Sequence< DstElementType > containerToSequence(const SrcType &i_Container)
DocumentType
constexpr rtl::OUStringConstExpr aPageHelpIds[NOOFPAGES]
Definition: pubdlg.cxx:61
IMPL_LINK_NOARG(SdPublishingDlg, DesignSelectHdl, weld::TreeView &, void)
Definition: pubdlg.cxx:872
IMPL_LINK(SdPublishingDlg, DesignHdl, weld::Toggleable &, rButton, void)
Definition: pubdlg.cxx:837
#define NOOFPAGES
Definition: pubdlg.cxx:52
static SvStream & operator>>(SvStream &rIn, SdPublishingDesign &rDesign)
Definition: pubdlg.cxx:230
constexpr OUStringLiteral KEY_QUALITY
Definition: pubdlg.cxx:58
static SvStream & WriteSdPublishingDesign(SvStream &rOut, const SdPublishingDesign &rDesign)
Definition: pubdlg.cxx:285
const sal_uInt16 nMagic
Definition: pubdlg.cxx:55
PublishingFormat
Definition: resltn.hxx:23
@ FORMAT_JPG
Definition: resltn.hxx:25
@ FORMAT_GIF
Definition: resltn.hxx:24
@ FORMAT_PNG
Definition: resltn.hxx:26
PublishingScript
Definition: resltn.hxx:30
@ SCRIPT_ASP
Definition: resltn.hxx:31
@ SCRIPT_PERL
Definition: resltn.hxx:32
OUString SdResId(TranslateId aId)
Definition: sdmod.cxx:83
OUString read_uInt16_lenPrefixed_uInt8s_ToOUString(SvStream &rStrm, rtl_TextEncoding eEnc)
std::size_t write_uInt16_lenPrefixed_uInt8s_FromOUString(SvStream &rStrm, std::u16string_view rStr, rtl_TextEncoding eEnc)
#define STR_HTMLEXP_DEFAULT_EXTENSION
Definition: strings.hxx:21
RET_OK
RET_NO
WinBits const WB_VSCROLL