diff options
author | Ptyl Dragon <ptyl@cloudon.com> | 2013-10-22 18:26:55 +0200 |
---|---|---|
committer | Ptyl Dragon <ptyl@cloudon.com> | 2013-10-24 11:30:55 +0200 |
commit | 2d09baa7802e5d5bf30bd4baafe690f06a1275ec (patch) | |
tree | e3b95507ab40a0f72c54bc14ed3254d4eb24fb75 /sw | |
parent | 6a2fbb827c424704e6a4e101710d31fae5d64680 (diff) |
tiledrendering extracts values when clicking render
Change-Id: I4b350dc6c796bb1af0740917e17ac79b2a259a0a
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/tiledrendering/tiledrendering.cxx | 46 | ||||
-rw-r--r-- | sw/qa/tiledrendering/tiledrendering.glade | 273 |
2 files changed, 14 insertions, 305 deletions
diff --git a/sw/qa/tiledrendering/tiledrendering.cxx b/sw/qa/tiledrendering/tiledrendering.cxx index 9f296bdac876..bfd20c327706 100644 --- a/sw/qa/tiledrendering/tiledrendering.cxx +++ b/sw/qa/tiledrendering/tiledrendering.cxx @@ -33,21 +33,26 @@ using namespace com::sun::star; class TiledRenderingDialog: public ModalDialog{ public: - TiledRenderingDialog() : ModalDialog(DIALOG_NO_PARENT, "TiledRendering", "qa/sw/ui/tiledrendering.ui"){ + TiledRenderingDialog() : ModalDialog(DIALOG_NO_PARENT, "TiledRendering", "qa/sw/ui/tiledrendering.ui") + { PushButton * renderButton; get(renderButton,"buttonRenderTile"); renderButton->SetClickHdl( LINK( this, TiledRenderingDialog, RenderHdl)); + SetStyle(GetStyle()|WB_CLOSEABLE); + } + virtual ~TiledRenderingDialog() + { } - virtual ~TiledRenderingDialog(){} DECL_LINK ( RenderHdl, Button * ); - sal_Int32 extractInt(const char * name){ - NumericField * pField; - get(pField,name); - OUString aString(pField->GetText()); - SAL_INFO("TiledRenderingDialog","param " << name << " returned " << aString); - return aString.toInt32(); + sal_Int32 extractInt(const char * name) + { + NumericField * pField; + get(pField,name); + OUString aString(pField->GetText()); + std::cerr << "param " << name << " returned " << aString <<"/n"; + return aString.toInt32(); } }; @@ -60,8 +65,7 @@ IMPL_LINK ( TiledRenderingDialog, RenderHdl, Button *, EMPTYARG ) extractInt("spinTilePosY"); extractInt("spinTileWidth"); extractInt("spinTileHeight"); - - return 1; + return 1; } void UIPreviewApp::Init() @@ -89,7 +93,6 @@ int UIPreviewApp::Main() // osl::File::getFileURLFromSystemPath(GetCommandLineParam(i), aFileUrl); // uifiles.push_back(aFileUrl); //} - //if (uifiles.empty()) //{ // fprintf(stderr, "Usage: ui-previewer file.ui\n"); @@ -105,21 +108,6 @@ int UIPreviewApp::Main() TiledRenderingDialog pDialog; pDialog.Execute(); -/* - { - VclBuilder aBuilder(pDialog, OUString(), "sw/qa/tiledrendering/tiledrendering.ui"); - Dialog *pRealDialog = dynamic_cast<Dialog*>(aBuilder.get_widget_root()); - - if (!pRealDialog) - pRealDialog = pDialog; - - if (pRealDialog) - { - pRealDialog->SetText(OUString("LibreOffice ui-previewer")); - pRealDialog->SetStyle(pDialog->GetStyle()|WB_CLOSEABLE); - pRealDialog->Execute(); - } - }*/ } catch (const uno::Exception &e) { @@ -129,12 +117,6 @@ int UIPreviewApp::Main() return EXIT_SUCCESS; } -void render(){ - - -} - - void vclmain::createApplication() { static UIPreviewApp aApp; diff --git a/sw/qa/tiledrendering/tiledrendering.glade b/sw/qa/tiledrendering/tiledrendering.glade deleted file mode 100644 index 35cee147d6cb..000000000000 --- a/sw/qa/tiledrendering/tiledrendering.glade +++ /dev/null @@ -1,273 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<interface> - <!-- interface-requires gtk+ 3.0 --> - <object class="GtkWindow" id="window1"> - <property name="can_focus">False</property> - <child> - <object class="GtkBox" id="box1"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <child> - <object class="GtkBox" id="box2"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="orientation">vertical</property> - <child> - <object class="GtkBox" id="box3"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <child> - <object class="GtkBox" id="box4"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="orientation">vertical</property> - <child> - <object class="GtkLabel" id="labelContentWidth"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">contentWidth</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="labelContentHeight"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">contentHeight</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="labelTilePosX"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">tilePosX</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">2</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="labelTilePoxY"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">tilePosY</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">3</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="labelTileWidth"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">tileWidth</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">4</property> - </packing> - </child> - <child> - <object class="GtkLabel" id="labelTileHeight"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="label" translatable="yes">tileHeight</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">5</property> - </packing> - </child> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkBox" id="box5"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="orientation">vertical</property> - <child> - <object class="GtkSpinButton" id="spinContextWidth"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkSpinButton" id="spinContextHeight"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - <child> - <object class="GtkSpinButton" id="spinTilePosX"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">2</property> - </packing> - </child> - <child> - <object class="GtkSpinButton" id="spinTilePosY"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">3</property> - </packing> - </child> - <child> - <object class="GtkSpinButton" id="spinTileWidth"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">4</property> - </packing> - </child> - <child> - <object class="GtkSpinButton" id="spinTileHeight"> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="invisible_char">•</property> - <property name="width_chars">1</property> - <property name="progress_pulse_step">1</property> - <property name="numeric">True</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">5</property> - </packing> - </child> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkBox" id="box6"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <child> - <object class="GtkButton" id="buttonRenderTile"> - <property name="label" translatable="yes">render tile</property> - <property name="use_action_appearance">False</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="receives_default">True</property> - <property name="use_action_appearance">False</property> - </object> - <packing> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="pack_type">end</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkButton" id="buttonChooseDocument"> - <property name="label" translatable="yes">choose document</property> - <property name="use_action_appearance">False</property> - <property name="visible">True</property> - <property name="can_focus">True</property> - <property name="receives_default">True</property> - <property name="use_action_appearance">False</property> - <property name="xalign">0.50999999046325684</property> - <property name="yalign">0.47999998927116394</property> - </object> - <packing> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - </object> - <packing> - <property name="expand">False</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">0</property> - </packing> - </child> - <child> - <object class="GtkImage" id="image1"> - <property name="visible">True</property> - <property name="can_focus">False</property> - <property name="stock">gtk-missing-image</property> - </object> - <packing> - <property name="expand">True</property> - <property name="fill">True</property> - <property name="position">1</property> - </packing> - </child> - </object> - </child> - </object> -</interface> |