summaryrefslogtreecommitdiff
path: root/sd/source
diff options
context:
space:
mode:
authorheiko tietze <tietze.heiko@gmail.com>2019-03-05 15:08:53 +0100
committerHeiko Tietze <tietze.heiko@gmail.com>2019-03-14 16:03:23 +0100
commit044fa501e95dcac8120767996dfb7ba8f25a703f (patch)
treef099c36335e7a6d200b0cfa21c0506cfb546aa76 /sd/source
parentff4ebd8c7df3d6aa7f0e3798635e6a461cfd936d (diff)
Resolves tdf#122707 - Replace listbox for print range by radio buttons
Some changes to the ui file (GtkGrid, alignment, radio buttons), setChoiceRadiosControlOpt() instead of *list Labels adjusted accordingly Patch partially reverts I62bd9affc9e065d7afcc60296a72eae4612b0ddd Change-Id: Ia06b8f2513d98fbdb1971477cf7b7127595d338c Reviewed-on: https://gerrit.libreoffice.org/68846 Tested-by: Jenkins Reviewed-by: Heiko Tietze <tietze.heiko@gmail.com>
Diffstat (limited to 'sd/source')
-rw-r--r--sd/source/ui/view/DocumentRenderer.cxx24
1 files changed, 22 insertions, 2 deletions
diff --git a/sd/source/ui/view/DocumentRenderer.cxx b/sd/source/ui/view/DocumentRenderer.cxx
index 149e328e7022..3750db72e59d 100644
--- a/sd/source/ui/view/DocumentRenderer.cxx
+++ b/sd/source/ui/view/DocumentRenderer.cxx
@@ -597,7 +597,7 @@ namespace {
nPrintRange = 1;
}
}
-
+/*
OUString aPrintRangeName( "PrintContent" );
aHelpIds.realloc( 1 );
aHelpIds[0] = ".HelpID:vcl:PrintDialog:PageContentType:ListBox";
@@ -606,7 +606,27 @@ namespace {
mbImpress ? CreateChoice( STR_IMPRESS_PRINT_UI_PAGE_RANGE_CHOICE, SAL_N_ELEMENTS(STR_IMPRESS_PRINT_UI_PAGE_RANGE_CHOICE ) ) :
CreateChoice( STR_DRAW_PRINT_UI_PAGE_RANGE_CHOICE, SAL_N_ELEMENTS(STR_DRAW_PRINT_UI_PAGE_RANGE_CHOICE ) ),
nPrintRange ) );
-
+*/
+ OUString aPrintRangeName( "PrintContent" );
+ aHelpIds.realloc( 5 );
+ aHelpIds[0] = ".HelpID:vcl:PrintDialog:PrintContent:RadioButton:0" ;
+ aHelpIds[1] = ".HelpID:vcl:PrintDialog:PrintContent:RadioButton:1" ;
+ aHelpIds[2] = ".HelpID:vcl:PrintDialog:PrintContent:RadioButton:2" ;
+ aHelpIds[3] = ".HelpID:vcl:PrintDialog:PrintContent:RadioButton:3" ;
+ aHelpIds[4] = ".HelpID:vcl:PrintDialog:PrintContent:RadioButton:4" ;
+ aWidgetIds.realloc( 5 );
+ aWidgetIds[0] = "rbAllPages";
+ aWidgetIds[1] = "rbRangePages";
+ aWidgetIds[2] = "rbEvenPages";
+ aWidgetIds[3] = "rbOddPages";
+ aWidgetIds[4] = "rbRangeSelection";
+
+ AddDialogControl( vcl::PrinterOptionsHelper::setChoiceRadiosControlOpt(aWidgetIds, OUString(),
+ aHelpIds, aPrintRangeName,
+ mbImpress ? CreateChoice(STR_IMPRESS_PRINT_UI_PAGE_RANGE_CHOICE, SAL_N_ELEMENTS(STR_IMPRESS_PRINT_UI_PAGE_RANGE_CHOICE)) :
+ CreateChoice(STR_DRAW_PRINT_UI_PAGE_RANGE_CHOICE, SAL_N_ELEMENTS(STR_DRAW_PRINT_UI_PAGE_RANGE_CHOICE)),
+ nPrintRange )
+ );
// create a an Edit dependent on "Pages" selected
vcl::PrinterOptionsHelper::UIControlOptions aPageRangeOpt( aPrintRangeName, 1, true );
AddDialogControl(vcl::PrinterOptionsHelper::setEditControlOpt("pagerange", "",