diff options
author | Xisco Fauli <anistenis@gmail.com> | 2011-07-06 17:49:00 +0200 |
---|---|---|
committer | Xisco Fauli <anistenis@gmail.com> | 2011-07-06 17:51:36 +0200 |
commit | 25a4c95fe85ba6910c61eb7011a482787679b1cf (patch) | |
tree | b7f9073939fdfde06e7f00eccb943d6cb21763d8 /wizards | |
parent | 8a0e1aa5115033ac877039081aa4473c89259403 (diff) |
create file when it doesn't exist
Diffstat (limited to 'wizards')
7 files changed, 182 insertions, 182 deletions
diff --git a/wizards/com/sun/star/wizards/common/FileAccess.py b/wizards/com/sun/star/wizards/common/FileAccess.py index 384582b71899..3397d7138cf5 100644 --- a/wizards/com/sun/star/wizards/common/FileAccess.py +++ b/wizards/com/sun/star/wizards/common/FileAccess.py @@ -485,9 +485,9 @@ class FileAccess(object): try: if childPath is not None: path = self.filenameConverter.getSystemPathFromFileURL(path) - f = open(path,childPath) + f = open(path,childPath, 'w') else: - f = open(path) + f = open(path, 'w') r = self.filenameConverter.getFileURLFromSystemPath(path, osPath.abspath(path)) diff --git a/wizards/com/sun/star/wizards/document/OfficeDocument.py b/wizards/com/sun/star/wizards/document/OfficeDocument.py index f053baebe703..f2fc2cb76e21 100644 --- a/wizards/com/sun/star/wizards/document/OfficeDocument.py +++ b/wizards/com/sun/star/wizards/document/OfficeDocument.py @@ -188,7 +188,7 @@ class OfficeDocument(object): oStoreProperties[1].Name = "InteractionHandler" oStoreProperties[1].Value = xMSF.createInstance( "com.sun.star.comp.uui.UUIInteractionHandler") - else: + else: oStoreProperties = range(0) if StorePath.startswith("file://"): @@ -200,7 +200,7 @@ class OfficeDocument(object): xComponent.storeToURL( unohelper.absolutize( unohelper.systemPathToFileUrl(sPath), - unohelper.systemPathToFileUrl(sFile)), + unohelper.systemPathToFileUrl(sFile)), tuple(oStoreProperties)) return True except ErrorCodeIOException: diff --git a/wizards/com/sun/star/wizards/letter/LetterDocument.py b/wizards/com/sun/star/wizards/letter/LetterDocument.py index 517d0c669adb..ea797210ba7d 100644 --- a/wizards/com/sun/star/wizards/letter/LetterDocument.py +++ b/wizards/com/sun/star/wizards/letter/LetterDocument.py @@ -106,12 +106,12 @@ class LetterDocument(TextDocument): myFieldHandler.changeUserFieldContent( "Street", Helper.getUnoObjectbyName(oUserDataAccess, "street")) myFieldHandler.changeUserFieldContent( - "PostCode", + "PostCode", Helper.getUnoObjectbyName(oUserDataAccess, "postalcode")) myFieldHandler.changeUserFieldContent( "City", Helper.getUnoObjectbyName(oUserDataAccess, "l")) myFieldHandler.changeUserFieldContent( - PropertyNames.PROPERTY_STATE, + PropertyNames.PROPERTY_STATE, Helper.getUnoObjectbyName(oUserDataAccess, "st")) except Exception: traceback.print_exc() @@ -167,91 +167,91 @@ class BusinessPaperObject(object): try: self.xFrame = \ TextDocument.xTextDocument.createInstance( - "com.sun.star.text.TextFrame") + "com.sun.star.text.TextFrame") self.setFramePosition() Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "AnchorType", AT_PAGE) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "SizeType", FIX) - + Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "TextWrap", THROUGHT) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "Opaque", True); Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "BackColor", 15790320) - + myBorder = BorderLine() myBorder.OuterLineWidth = 0 Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "LeftBorder", myBorder) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "RightBorder", myBorder) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "TopBorder", myBorder) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "BottomBorder", myBorder) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "Print", False) - + xTextCursor = \ TextDocument.xTextDocument.Text.createTextCursor() xTextCursor.gotoEnd(True) xText = TextDocument.xTextDocument.Text xText.insertTextContent( - xTextCursor, self.xFrame, + xTextCursor, self.xFrame, False) - + xFrameText = self.xFrame.Text xFrameCursor = xFrameText.createTextCursor() xFrameCursor.setPropertyValue("CharWeight", BOLD) xFrameCursor.setPropertyValue("CharColor", 16777215) xFrameCursor.setPropertyValue("CharFontName", "Albany") xFrameCursor.setPropertyValue("CharHeight", 18) - + xFrameText.insertString(xFrameCursor, FrameText, False) except Exception: traceback.print_exc() - + def setFramePosition(self): try: Helper.setUnoPropertyValue( self.xFrame, "HoriOrient", NONEHORI) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "VertOrient", NONEVERT) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, PropertyNames.PROPERTY_HEIGHT, self.iHeight) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, PropertyNames.PROPERTY_WIDTH, self.iWidth) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "HoriOrientPosition", self.iXPos) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "VertOrientPosition", self.iYPos) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "HoriOrientRelation", PAGE_FRAME) Helper.setUnoPropertyValue( - self.xFrame, + self.xFrame, "VertOrientRelation", PAGE_FRAME) except Exception: traceback.print_exc() - + def removeFrame(self): if self.xFrame is not None: try: diff --git a/wizards/com/sun/star/wizards/letter/LetterWizardDialog.py b/wizards/com/sun/star/wizards/letter/LetterWizardDialog.py index ac87206f243c..35158a3ea0ac 100644 --- a/wizards/com/sun/star/wizards/letter/LetterWizardDialog.py +++ b/wizards/com/sun/star/wizards/letter/LetterWizardDialog.py @@ -12,18 +12,18 @@ class LetterWizardDialog(WizardDialog): self.resources = LetterWizardDialogResources(xmsf) Helper.setUnoPropertyValues( self.xDialogModel, - ("Closeable", + ("Closeable", PropertyNames.PROPERTY_HEIGHT, - "Moveable", - PropertyNames.PROPERTY_NAME, - PropertyNames.PROPERTY_POSITION_X, - PropertyNames.PROPERTY_POSITION_Y, - PropertyNames.PROPERTY_STEP, - PropertyNames.PROPERTY_TABINDEX, - "Title", - PropertyNames.PROPERTY_WIDTH), + "Moveable", + PropertyNames.PROPERTY_NAME, + PropertyNames.PROPERTY_POSITION_X, + PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_STEP, + PropertyNames.PROPERTY_TABINDEX, + "Title", + PropertyNames.PROPERTY_WIDTH), (True, 210, True, - "LetterWizardDialog", 104, 52, 1, 1, + "LetterWizardDialog", 104, 52, 1, 1, self.resources.resLetterWizardDialog_title, 310)) self.fontDescriptor1 = \ uno.createUnoStruct('com.sun.star.awt.FontDescriptor') @@ -41,7 +41,7 @@ class LetterWizardDialog(WizardDialog): def buildStep1(self): self.optBusinessLetter = self.insertRadioButton( - "optBusinessLetter", OPTBUSINESSLETTER_ITEM_CHANGED, + "optBusinessLetter", OPTBUSINESSLETTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -51,11 +51,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, HelpIds.getHelpIdString(HID + 1), + (8, HelpIds.getHelpIdString(HID + 1), self.resources.resoptBusinessLetter_value, "optBusinessLetter", 97, 28, 1, 1, 184), self) self.optPrivOfficialLetter = self.insertRadioButton( - "optPrivOfficialLetter", OPTPRIVOFFICIALLETTER_ITEM_CHANGED, + "optPrivOfficialLetter", OPTPRIVOFFICIALLETTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -65,11 +65,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, HelpIds.getHelpIdString(HID + 2), - self.resources.resoptPrivOfficialLetter_value, + (8, HelpIds.getHelpIdString(HID + 2), + self.resources.resoptPrivOfficialLetter_value, "optPrivOfficialLetter", 97, 74, 1, 2, 184), self) self.optPrivateLetter = self.insertRadioButton( - "optPrivateLetter", OPTPRIVATELETTER_ITEM_CHANGED, + "optPrivateLetter", OPTPRIVATELETTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -79,11 +79,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, HelpIds.getHelpIdString(HID + 3), - self.resources.resoptPrivateLetter_value, + (8, HelpIds.getHelpIdString(HID + 3), + self.resources.resoptPrivateLetter_value, "optPrivateLetter", 97, 106, 1, 3, 184), self) self.lstBusinessStyle = self.insertListBox( - "lstBusinessStyle", LSTBUSINESSSTYLE_ACTION_PERFORMED, + "lstBusinessStyle", LSTBUSINESSSTYLE_ACTION_PERFORMED, LSTBUSINESSSTYLE_ITEM_CHANGED, ("Dropdown", PropertyNames.PROPERTY_HEIGHT, @@ -98,7 +98,7 @@ class LetterWizardDialog(WizardDialog): "lstBusinessStyle", 180, 40, 1, 4, 74), self) self.chkBusinessPaper = self.insertCheckBox( - "chkBusinessPaper", CHKBUSINESSPAPER_ITEM_CHANGED, + "chkBusinessPaper", CHKBUSINESSPAPER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -109,11 +109,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, HelpIds.getHelpIdString(HID + 5), - self.resources.reschkBusinessPaper_value, + (8, HelpIds.getHelpIdString(HID + 5), + self.resources.reschkBusinessPaper_value, "chkBusinessPaper", 110, 56, 0, 1, 5, 168), self) self.lstPrivOfficialStyle = self.insertListBox( - "lstPrivOfficialStyle", LSTPRIVOFFICIALSTYLE_ACTION_PERFORMED, + "lstPrivOfficialStyle", LSTPRIVOFFICIALSTYLE_ACTION_PERFORMED, LSTPRIVOFFICIALSTYLE_ITEM_CHANGED, ("Dropdown", PropertyNames.PROPERTY_HEIGHT, @@ -124,7 +124,7 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (True, 12, HelpIds.getHelpIdString(HID + 6), + (True, 12, HelpIds.getHelpIdString(HID + 6), "lstPrivOfficialStyle", 180, 86, 1, 6, 74), self) self.lstPrivateStyle = self.insertListBox( "lstPrivateStyle", LSTPRIVATESTYLE_ACTION_PERFORMED, @@ -138,10 +138,10 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (True, 12, HelpIds.getHelpIdString(HID + 7), + (True, 12, HelpIds.getHelpIdString(HID + 7), "lstPrivateStyle", 180, 118, 1, 7, 74), self) self.lblBusinessStyle = self.insertLabel( - "lblBusinessStyle", + "lblBusinessStyle", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -150,10 +150,10 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, self.resources.reslblBusinessStyle_value, + (8, self.resources.reslblBusinessStyle_value, "lblBusinessStyle", 110, 42, 1, 48, 60)) self.lblPrivOfficialStyle = self.insertLabel( - "lblPrivOfficialStyle", + "lblPrivOfficialStyle", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -168,7 +168,7 @@ class LetterWizardDialog(WizardDialog): "lblTitle1", ("FontDescriptor", PropertyNames.PROPERTY_HEIGHT, - PropertyNames.PROPERTY_LABEL, + PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, @@ -176,11 +176,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (self.fontDescriptor6, 16, - self.resources.reslblTitle1_value, True, + (self.fontDescriptor6, 16, + self.resources.reslblTitle1_value, True, "lblTitle1", 91, 8, 1, 55, 212)) self.lblPrivateStyle = self.insertLabel( - "lblPrivateStyle", + "lblPrivateStyle", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -192,7 +192,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblPrivateStyle_value, "lblPrivateStyle", 110, 120, 1, 74, 60)) self.lblIntroduction = self.insertLabel( - "lblIntroduction", + "lblIntroduction", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, @@ -202,7 +202,7 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (39, self.resources.reslblIntroduction_value, + (39, self.resources.reslblIntroduction_value, True, "lblIntroduction", 104, 145, 1, 80, 199)) self.ImageControl3 = self.insertInfoImage(92, 145, 1) @@ -210,7 +210,7 @@ class LetterWizardDialog(WizardDialog): def buildStep2(self): self.chkPaperCompanyLogo = self.insertCheckBox( "chkPaperCompanyLogo", - CHKPAPERCOMPANYLOGO_ITEM_CHANGED, + CHKPAPERCOMPANYLOGO_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -222,11 +222,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), (8, HelpIds.getHelpIdString(HID + 8), - self.resources.reschkPaperCompanyLogo_value, + self.resources.reschkPaperCompanyLogo_value, "chkPaperCompanyLogo", 97, 28, 0, 2, 8, 68), self) self.numLogoHeight = self.insertNumericField( "numLogoHeight", - NUMLOGOHEIGHT_TEXT_CHANGED, + NUMLOGOHEIGHT_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -241,7 +241,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 9), "numLogoHeight", 138, 40, True, 2, True, 9, 3, 30), self) self.numLogoX = self.insertNumericField( - "numLogoX", NUMLOGOX_TEXT_CHANGED, + "numLogoX", NUMLOGOX_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -255,7 +255,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 10), "numLogoX", 266, 40, True, 2, 10, 0, 30), self) self.numLogoWidth = self.insertNumericField( - "numLogoWidth", NUMLOGOWIDTH_TEXT_CHANGED, + "numLogoWidth", NUMLOGOWIDTH_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -269,7 +269,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 11), "numLogoWidth", 138, 56, True, 2, 11, 3.8, 30), self) self.numLogoY = self.insertNumericField( - "numLogoY", NUMLOGOY_TEXT_CHANGED, + "numLogoY", NUMLOGOY_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -280,10 +280,10 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_TABINDEX, "Value", PropertyNames.PROPERTY_WIDTH), - (12, HelpIds.getHelpIdString(HID + 12), + (12, HelpIds.getHelpIdString(HID + 12), "numLogoY", 266, 56, True, 2, 12, -3.4, 30), self) self.chkPaperCompanyAddress = self.insertCheckBox( - "chkPaperCompanyAddress", CHKPAPERCOMPANYADDRESS_ITEM_CHANGED, + "chkPaperCompanyAddress", CHKPAPERCOMPANYADDRESS_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -298,7 +298,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkPaperCompanyAddress_value, "chkPaperCompanyAddress", 98, 84, 0, 2, 13, 68), self) self.numAddressHeight = self.insertNumericField( - "numAddressHeight", NUMADDRESSHEIGHT_TEXT_CHANGED, + "numAddressHeight", NUMADDRESSHEIGHT_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -313,7 +313,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 14), "numAddressHeight", 138, 96, True, 2, True, 14, 3, 30), self) self.numAddressX = self.insertNumericField( - "numAddressX", NUMADDRESSX_TEXT_CHANGED, + "numAddressX", NUMADDRESSX_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -327,7 +327,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 15), "numAddressX", 266, 96, True, 2, 15, 3.8, 30), self) self.numAddressWidth = self.insertNumericField( - "numAddressWidth", NUMADDRESSWIDTH_TEXT_CHANGED, + "numAddressWidth", NUMADDRESSWIDTH_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -341,7 +341,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 16), "numAddressWidth", 138, 112, True, 2, 16, 13.8, 30), self) self.numAddressY = self.insertNumericField( - "numAddressY", NUMADDRESSY_TEXT_CHANGED, + "numAddressY", NUMADDRESSY_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -355,7 +355,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 17), "numAddressY", 266, 112, True, 2, 17, -3.4, 30), self) self.chkCompanyReceiver = self.insertCheckBox( - "chkCompanyReceiver", CHKCOMPANYRECEIVER_ITEM_CHANGED, + "chkCompanyReceiver", CHKCOMPANYRECEIVER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -369,7 +369,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkCompanyReceiver_value, "chkCompanyReceiver", 103, 131, 0, 2, 18, 185), self) self.chkPaperFooter = self.insertCheckBox( - "chkPaperFooter", CHKPAPERFOOTER_ITEM_CHANGED, + "chkPaperFooter", CHKPAPERFOOTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -380,11 +380,11 @@ class LetterWizardDialog(WizardDialog): PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, PropertyNames.PROPERTY_WIDTH), - (8, HelpIds.getHelpIdString(HID + 19), + (8, HelpIds.getHelpIdString(HID + 19), self.resources.reschkPaperFooter_value, "chkPaperFooter", 97, 158, 0, 2, 19, 68), self) self.numFooterHeight = self.insertNumericField( - "numFooterHeight", NUMFOOTERHEIGHT_TEXT_CHANGED, + "numFooterHeight", NUMFOOTERHEIGHT_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -398,7 +398,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 20), "numFooterHeight", 236, 156, True, 2, 20, 5, 30), self) self.lblLogoHeight = self.insertLabel( - "lblLogoHeight", + "lblLogoHeight", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -410,7 +410,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblLogoHeight_value, "lblLogoHeight", 103, 42, 2, 68, 32)) self.lblLogoWidth = self.insertLabel( - "lblLogoWidth", + "lblLogoWidth", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -422,7 +422,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblLogoWidth_value, "lblLogoWidth", 103, 58, 2, 69, 32)) self.FixedLine5 = self.insertFixedLine( - "FixedLine5", + "FixedLine5", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, @@ -433,7 +433,7 @@ class LetterWizardDialog(WizardDialog): (2, "FixedLine5", 90, 78, 2, 70, 215)) self.FixedLine6 = self.insertFixedLine( - "FixedLine6", + "FixedLine6", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, @@ -444,7 +444,7 @@ class LetterWizardDialog(WizardDialog): (2, "FixedLine6", 90, 150, 2, 71, 215)) self.lblFooterHeight = self.insertLabel( - "lblFooterHeight", + "lblFooterHeight", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -456,7 +456,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblFooterHeight_value, "lblFooterHeight", 200, 158, 2, 72, 32)) self.lblLogoX = self.insertLabel( - "lblLogoX", + "lblLogoX", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -468,7 +468,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblLogoX_value, "lblLogoX", 170, 42, 2, 84, 94)) self.lblLogoY = self.insertLabel( - "lblLogoY", + "lblLogoY", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -480,7 +480,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblLogoY_value, "lblLogoY", 170, 58, 2, 85, 94)) self.lblAddressHeight = self.insertLabel( - "lblAddressHeight", + "lblAddressHeight", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -492,7 +492,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblAddressHeight_value, "lblAddressHeight", 103, 98, 2, 86, 32)) self.lblAddressWidth = self.insertLabel( - "lblAddressWidth", + "lblAddressWidth", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -504,7 +504,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblAddressWidth_value, "lblAddressWidth", 103, 114, 2, 87, 32)) self.lblAddressX = self.insertLabel( - "lblAddressX", + "lblAddressX", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -516,7 +516,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblAddressX_value, "lblAddressX", 170, 98, 2, 88, 94)) self.lblAddressY = self.insertLabel( - "lblAddressY", + "lblAddressY", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -529,7 +529,7 @@ class LetterWizardDialog(WizardDialog): "lblAddressY", 170, 114, 2, 89, 94)) self.lblTitle2 = self.insertLabel( "lblTitle2", - ("FontDescriptor", + ("FontDescriptor", PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, @@ -545,8 +545,8 @@ class LetterWizardDialog(WizardDialog): def buildStep3(self): self.lstLetterNorm = self.insertListBox( - "lstLetterNorm", - LSTLETTERNORM_ACTION_PERFORMED, + "lstLetterNorm", + LSTLETTERNORM_ACTION_PERFORMED, LSTLETTERNORM_ITEM_CHANGED, ("Dropdown", PropertyNames.PROPERTY_HEIGHT, @@ -560,13 +560,13 @@ class LetterWizardDialog(WizardDialog): (True, 12, HelpIds.getHelpIdString(HID + 21), "lstLetterNorm", 210, 34, 3, 21, 74), self) self.chkUseLogo = self.insertCheckBox( - "chkUseLogo", CHKUSELOGO_ITEM_CHANGED, + "chkUseLogo", CHKUSELOGO_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, - PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, @@ -575,14 +575,14 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseLogo_value, "chkUseLogo", 97, 54, 0, 3, 22, 212), self) self.chkUseAddressReceiver = self.insertCheckBox( - "chkUseAddressReceiver", - CHKUSEADDRESSRECEIVER_ITEM_CHANGED, + "chkUseAddressReceiver", + CHKUSEADDRESSRECEIVER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, - PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, @@ -591,7 +591,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseAddressReceiver_value, "chkUseAddressReceiver", 97, 69, 0, 3, 23, 212), self) self.chkUseSigns = self.insertCheckBox( - "chkUseSigns", CHKUSESIGNS_ITEM_CHANGED, + "chkUseSigns", CHKUSESIGNS_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -606,7 +606,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseSigns_value, "chkUseSigns", 97, 82, 0, 3, 24, 212), self) self.chkUseSubject = self.insertCheckBox( - "chkUseSubject", CHKUSESUBJECT_ITEM_CHANGED, + "chkUseSubject", CHKUSESUBJECT_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -621,7 +621,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseSubject_value, "chkUseSubject", 97, 98, 0, 3, 25, 212), self) self.chkUseSalutation = self.insertCheckBox( - "chkUseSalutation", CHKUSESALUTATION_ITEM_CHANGED, + "chkUseSalutation", CHKUSESALUTATION_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -652,7 +652,7 @@ class LetterWizardDialog(WizardDialog): (True, 12, HelpIds.getHelpIdString(HID + 27), "lstSalutation", 210, 110, 3, 27, 74), self) self.chkUseBendMarks = self.insertCheckBox( - "chkUseBendMarks", CHKUSEBENDMARKS_ITEM_CHANGED, + "chkUseBendMarks", CHKUSEBENDMARKS_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -667,7 +667,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseBendMarks_value, "chkUseBendMarks", 97, 127, 0, 3, 28, 212), self) self.chkUseGreeting = self.insertCheckBox( - "chkUseGreeting", CHKUSEGREETING_ITEM_CHANGED, + "chkUseGreeting", CHKUSEGREETING_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -696,13 +696,13 @@ class LetterWizardDialog(WizardDialog): (True, 12, HelpIds.getHelpIdString(HID + 30), "lstGreeting", 210, 141, 3, 30, 74), self) self.chkUseFooter = self.insertCheckBox( - "chkUseFooter", CHKUSEFOOTER_ITEM_CHANGED, + "chkUseFooter", CHKUSEFOOTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, - PropertyNames.PROPERTY_POSITION_Y, + PropertyNames.PROPERTY_POSITION_Y, PropertyNames.PROPERTY_STATE, PropertyNames.PROPERTY_STEP, PropertyNames.PROPERTY_TABINDEX, @@ -711,7 +711,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkUseFooter_value, "chkUseFooter", 97, 158, 0, 3, 31, 212), self) self.lblLetterNorm = self.insertLabel( - "lblLetterNorm", + "lblLetterNorm", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, @@ -741,7 +741,7 @@ class LetterWizardDialog(WizardDialog): def buildStep4(self): self.optSenderPlaceholder = self.insertRadioButton( - "optSenderPlaceholder", OPTSENDERPLACEHOLDER_ITEM_CHANGED, + "optSenderPlaceholder", OPTSENDERPLACEHOLDER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -755,7 +755,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptSenderPlaceholder_value, "optSenderPlaceholder", 104, 42, 4, 32, 149), self) self.optSenderDefine = self.insertRadioButton( - "optSenderDefine", OPTSENDERDEFINE_ITEM_CHANGED, + "optSenderDefine", OPTSENDERDEFINE_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -769,7 +769,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptSenderDefine_value, "optSenderDefine", 104, 54, 4, 33, 149), self) self.txtSenderName = self.insertTextField( - "txtSenderName", TXTSENDERNAME_TEXT_CHANGED, + "txtSenderName", TXTSENDERNAME_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -781,7 +781,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 34), "txtSenderName", 182, 67, 4, 34, 119), self) self.txtSenderStreet = self.insertTextField( - "txtSenderStreet", TXTSENDERSTREET_TEXT_CHANGED, + "txtSenderStreet", TXTSENDERSTREET_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -793,7 +793,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 35), "txtSenderStreet", 182, 81, 4, 35, 119), self) self.txtSenderPostCode = self.insertTextField( - "txtSenderPostCode", TXTSENDERPOSTCODE_TEXT_CHANGED, + "txtSenderPostCode", TXTSENDERPOSTCODE_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -805,7 +805,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 36), "txtSenderPostCode", 182, 95, 4, 36, 25), self) self.txtSenderState = self.insertTextField( - "txtSenderState", TXTSENDERSTATE_TEXT_CHANGED, + "txtSenderState", TXTSENDERSTATE_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -817,7 +817,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 37), "txtSenderState", 211, 95, 4, 37, 21), self) self.txtSenderCity = self.insertTextField( - "txtSenderCity", TXTSENDERCITY_TEXT_CHANGED, + "txtSenderCity", TXTSENDERCITY_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -829,7 +829,7 @@ class LetterWizardDialog(WizardDialog): (12, HelpIds.getHelpIdString(HID + 38), "txtSenderCity", 236, 95, 4, 38, 65), self) self.optReceiverPlaceholder = self.insertRadioButton( - "optReceiverPlaceholder", OPTRECEIVERPLACEHOLDER_ITEM_CHANGED, + "optReceiverPlaceholder", OPTRECEIVERPLACEHOLDER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -843,7 +843,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptReceiverPlaceholder_value, "optReceiverPlaceholder", 104, 145, 4, 39, 200), self) self.optReceiverDatabase = self.insertRadioButton( - "optReceiverDatabase", OPTRECEIVERDATABASE_ITEM_CHANGED, + "optReceiverDatabase", OPTRECEIVERDATABASE_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -857,7 +857,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptReceiverDatabase_value, "optReceiverDatabase", 104, 157, 4, 40, 200), self) self.lblSenderAddress = self.insertLabel( - "lblSenderAddress", + "lblSenderAddress", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -869,7 +869,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblSenderAddress_value, "lblSenderAddress", 97, 28, 4, 64, 136)) self.FixedLine2 = self.insertFixedLine( - "FixedLine2", + "FixedLine2", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_NAME, PropertyNames.PROPERTY_POSITION_X, @@ -880,7 +880,7 @@ class LetterWizardDialog(WizardDialog): (5, "FixedLine2", 90, 126, 4, 75, 212)) self.lblReceiverAddress = self.insertLabel( - "lblReceiverAddress", + "lblReceiverAddress", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -892,7 +892,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblReceiverAddress_value, "lblReceiverAddress", 97, 134, 4, 76, 136)) self.lblSenderName = self.insertLabel( - "lblSenderName", + "lblSenderName", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -904,7 +904,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblSenderName_value, "lblSenderName", 113, 69, 4, 77, 68)) self.lblSenderStreet = self.insertLabel( - "lblSenderStreet", + "lblSenderStreet", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -916,7 +916,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblSenderStreet_value, "lblSenderStreet", 113, 82, 4, 78, 68)) self.lblPostCodeCity = self.insertLabel( - "lblPostCodeCity", + "lblPostCodeCity", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -945,7 +945,7 @@ class LetterWizardDialog(WizardDialog): def buildStep5(self): self.txtFooter = self.insertTextField( - "txtFooter", TXTFOOTER_TEXT_CHANGED, + "txtFooter", TXTFOOTER_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_MULTILINE, @@ -958,7 +958,7 @@ class LetterWizardDialog(WizardDialog): (47, HelpIds.getHelpIdString(HID + 41), True, "txtFooter", 97, 40, 5, 41, 203), self) self.chkFooterNextPages = self.insertCheckBox( - "chkFooterNextPages", CHKFOOTERNEXTPAGES_ITEM_CHANGED, + "chkFooterNextPages", CHKFOOTERNEXTPAGES_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -973,7 +973,7 @@ class LetterWizardDialog(WizardDialog): self.resources.reschkFooterNextPages_value, "chkFooterNextPages", 97, 92, 0, 5, 42, 202), self) self.chkFooterPageNumbers = self.insertCheckBox( - "chkFooterPageNumbers", CHKFOOTERPAGENUMBERS_ITEM_CHANGED, + "chkFooterPageNumbers", CHKFOOTERPAGENUMBERS_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -1018,7 +1018,7 @@ class LetterWizardDialog(WizardDialog): def buildStep6(self): self.txtTemplateName = self.insertTextField( - "txtTemplateName", TXTTEMPLATENAME_TEXT_CHANGED, + "txtTemplateName", TXTTEMPLATENAME_TEXT_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_NAME, @@ -1032,7 +1032,7 @@ class LetterWizardDialog(WizardDialog): "txtTemplateName", 202, 56, 6, 44, self.resources.restxtTemplateName_value, 100), self) self.optCreateLetter = self.insertRadioButton( - "optCreateLetter", OPTCREATELETTER_ITEM_CHANGED, + "optCreateLetter", OPTCREATELETTER_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -1046,7 +1046,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptCreateLetter_value, "optCreateLetter", 104, 111, 6, 50, 198), self) self.optMakeChanges = self.insertRadioButton( - "optMakeChanges", OPTMAKECHANGES_ITEM_CHANGED, + "optMakeChanges", OPTMAKECHANGES_ITEM_CHANGED, (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_HELPURL, PropertyNames.PROPERTY_LABEL, @@ -1060,7 +1060,7 @@ class LetterWizardDialog(WizardDialog): self.resources.resoptMakeChanges_value, "optMakeChanges", 104, 123, 6, 51, 198), self) self.lblFinalExplanation1 = self.insertLabel( - "lblFinalExplanation1", + "lblFinalExplanation1", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, @@ -1073,7 +1073,7 @@ class LetterWizardDialog(WizardDialog): (26, self.resources.reslblFinalExplanation1_value, True, "lblFinalExplanation1", 97, 28, 6, 52, 205)) self.lblProceed = self.insertLabel( - "lblProceed", + "lblProceed", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, @@ -1085,7 +1085,7 @@ class LetterWizardDialog(WizardDialog): (8, self.resources.reslblProceed_value, "lblProceed", 97, 100, 6, 53, 204)) self.lblFinalExplanation2 = self.insertLabel( - "lblFinalExplanation2", + "lblFinalExplanation2", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_MULTILINE, @@ -1113,7 +1113,7 @@ class LetterWizardDialog(WizardDialog): "private:resource/dbu/image/19205", "ImageControl2", 92, 145, False, 6, 66, 10)) self.lblTemplateName = self.insertLabel( - "lblTemplateName", + "lblTemplateName", (PropertyNames.PROPERTY_HEIGHT, PropertyNames.PROPERTY_LABEL, PropertyNames.PROPERTY_NAME, diff --git a/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py b/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py index d24728612947..bc1e3ec1fae1 100644 --- a/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py +++ b/wizards/com/sun/star/wizards/letter/LetterWizardDialogImpl.py @@ -157,14 +157,14 @@ class LetterWizardDialogImpl(LetterWizardDialog): if not self.filenameChanged: if fileAccess.exists(self.sPath, True): answer = SystemDialog.showMessageBox( - self.xMSF, "MessBox", YES_NO + DEF_NO, - self.resources.resOverwriteWarning, + self.xMSF, "MessBox", YES_NO + DEF_NO, + self.resources.resOverwriteWarning, self.xUnoDialog.Peer) if answer == 3: return False self.myLetterDoc.setWizardTemplateDocInfo( - self.resources.resLetterWizardDialog_title, + self.resources.resLetterWizardDialog_title, self.resources.resTemplateDescription) self.myLetterDoc.killEmptyUserFields() self.myLetterDoc.keepLogoFrame = self.chkUseLogo.State != 0 @@ -190,7 +190,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.myLetterDoc.killEmptyFrames() self.bSaveSuccess = \ OfficeDocument.store( - self.xMSF, TextDocument.xTextDocument, + self.xMSF, TextDocument.xTextDocument, self.sPath, "writer8_template") if self.bSaveSuccess: self.saveConfiguration() @@ -218,7 +218,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): loadValues[0].Value = True oDoc = OfficeDocument.load( - Desktop.getDesktop(self.xMSF), + Desktop.getDesktop(self.xMSF), self.sPath, "_default", loadValues) myViewHandler = ViewHandler(self.xMSF, oDoc) myViewHandler.setViewSetting("ZoomType", OPTIMAL) @@ -361,18 +361,18 @@ class LetterWizardDialogImpl(LetterWizardDialog): def optReceiverPlaceholderItemChanged(self): OfficeDocument.attachEventCall( - TextDocument.xTextDocument, "OnNew", "StarBasic", + TextDocument.xTextDocument, "OnNew", "StarBasic", "macro:///Template.Correspondence.Placeholder()") def optReceiverDatabaseItemChanged(self): OfficeDocument.attachEventCall( - TextDocument.xTextDocument, "OnNew", "StarBasic", + TextDocument.xTextDocument, "OnNew", "StarBasic", "macro:///Template.Correspondence.Database()") def lstBusinessStyleItemChanged(self): TextDocument.xTextDocument = \ self.myLetterDoc.loadAsPreview( - self.BusinessFiles[1][self.lstBusinessStyle.SelectedItemPos], + self.BusinessFiles[1][self.lstBusinessStyle.SelectedItemPos], False) self.myLetterDoc.xTextDocument.lockControllers() self.initializeElements() @@ -384,7 +384,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): def lstPrivOfficialStyleItemChanged(self): TextDocument.xTextDocument = \ self.myLetterDoc.loadAsPreview( - self.OfficialFiles[1][self.lstPrivOfficialStyle.SelectedItemPos], + self.OfficialFiles[1][self.lstPrivOfficialStyle.SelectedItemPos], False) self.myLetterDoc.xTextDocument.lockControllers() self.initializeElements() @@ -396,7 +396,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): def lstPrivateStyleItemChanged(self): TextDocument.xTextDocument = \ self.myLetterDoc.loadAsPreview( - self.PrivateFiles[1][self.lstPrivateStyle.getSelectedItemPos()], + self.PrivateFiles[1][self.lstPrivateStyle.getSelectedItemPos()], False) self.myLetterDoc.xTextDocument.lockControllers() self.initializeElements() @@ -450,9 +450,9 @@ class LetterWizardDialogImpl(LetterWizardDialog): if self.numLogoHeight.Value == 0: self.numLogoHeight.Value = 0.1 self.BusCompanyLogo = BusinessPaperObject( - "Company Logo", int(self.numLogoWidth.Value * 1000), + "Company Logo", int(self.numLogoWidth.Value * 1000), int(self.numLogoHeight.Value * 1000), - int(self.numLogoX.Value * 1000), + int(self.numLogoX.Value * 1000), self.numLogoY.Value * 1000) self.setControlProperty( "numLogoHeight", PropertyNames.PROPERTY_ENABLED, True) @@ -502,8 +502,8 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.numAddressHeight.Value = 0.1 self.BusCompanyAddress = BusinessPaperObject( - "Company Address", int(self.numAddressWidth.Value * 1000), - int(self.numAddressHeight.Value * 1000), + "Company Address", int(self.numAddressWidth.Value * 1000), + int(self.numAddressHeight.Value * 1000), int(self.numAddressX.Value * 1000), int(self.numAddressY.Value * 1000)) self.setControlProperty( @@ -574,7 +574,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): xReceiverFrame, "VertOrientPosition")) iReceiverHeight = int(0.5 * 1000) self.BusCompanyAddressReceiver = BusinessPaperObject( - " ", iFrameWidth, iReceiverHeight, iFrameX, + " ", iFrameWidth, iReceiverHeight, iFrameX, iFrameY - iReceiverHeight) self.setPossibleAddressReceiver(False) except NoSuchElementException: @@ -603,8 +603,8 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.numFooterHeight.Value = 0.1 self.BusFooter = BusinessPaperObject( - "Footer", self.myLetterDoc.DocSize.Width, - int(self.numFooterHeight.Value * 1000), 0, + "Footer", self.myLetterDoc.DocSize.Width, + int(self.numFooterHeight.Value * 1000), 0, int(self.myLetterDoc.DocSize.Height - \ (self.numFooterHeight.Value * 1000))) self.setControlProperty( @@ -639,7 +639,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): if self.myLetterDoc.hasElement("Sender Address Repeated"): rstatus = \ bool(self.getControlProperty( - "chkUseAddressReceiver", + "chkUseAddressReceiver", PropertyNames.PROPERTY_ENABLED)) \ and (self.chkUseAddressReceiver.State != 0) self.myLetterDoc.switchElement( @@ -679,7 +679,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): "First Page", bFooterPossible, self.chkFooterPageNumbers.State != 0, self.txtFooter.Text) self.myLetterDoc.switchFooter( - "Standard", bFooterPossible, + "Standard", bFooterPossible, self.chkFooterPageNumbers.State != 0, self.txtFooter.Text) BPaperItem = \ @@ -755,7 +755,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): "Salutation", self.lstSalutation.Text, self.chkUseSalutation.State != 0) self.setControlProperty( - "lstSalutation", PropertyNames.PROPERTY_ENABLED, + "lstSalutation", PropertyNames.PROPERTY_ENABLED, self.chkUseSalutation.State != 0) def lstSalutationItemChanged(self): @@ -767,7 +767,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.myLetterDoc.switchUserField( "Greeting", self.lstGreeting.Text, self.chkUseGreeting.State != 0) self.setControlProperty( - "lstGreeting", PropertyNames.PROPERTY_ENABLED, + "lstGreeting", PropertyNames.PROPERTY_ENABLED, self.chkUseGreeting.State != 0) def setDefaultForGreetingAndSalutation(self): @@ -884,7 +884,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.myLetterDoc.switchElement( "Sender Address", True) except Exception: - traceback.print_exc() + traceback.print_exc() def lstLetterNormItemChanged(self): sCurrentNorm = self.Norms[getCurrentLetter().cp_Norm] @@ -900,7 +900,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): def initializeSalutation(self): self.setControlProperty( - "lstSalutation", "StringItemList", + "lstSalutation", "StringItemList", self.resources.SalutationLabels) def initializeGreeting(self): @@ -991,13 +991,13 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.PrivateFiles = \ FileAccess.getFolderTitles(xMSF, "pri", sLetterPath) self.setControlProperty( - "lstBusinessStyle", "StringItemList", + "lstBusinessStyle", "StringItemList", tuple(self.BusinessFiles[0])) self.setControlProperty( - "lstPrivOfficialStyle", "StringItemList", + "lstPrivOfficialStyle", "StringItemList", tuple(self.OfficialFiles[0])) self.setControlProperty( - "lstPrivateStyle", "StringItemList", + "lstPrivateStyle", "StringItemList", tuple(self.PrivateFiles[0])) self.setControlProperty( "lstBusinessStyle", "SelectedItems", (0,)) @@ -1009,19 +1009,19 @@ class LetterWizardDialogImpl(LetterWizardDialog): def initializeElements(self): self.setControlProperty( - "chkUseLogo", PropertyNames.PROPERTY_ENABLED, + "chkUseLogo", PropertyNames.PROPERTY_ENABLED, self.myLetterDoc.hasElement("Company Logo")) self.setControlProperty( - "chkUseBendMarks", PropertyNames.PROPERTY_ENABLED, + "chkUseBendMarks", PropertyNames.PROPERTY_ENABLED, self.myLetterDoc.hasElement("Bend Marks")) self.setControlProperty( - "chkUseAddressReceiver", PropertyNames.PROPERTY_ENABLED, + "chkUseAddressReceiver", PropertyNames.PROPERTY_ENABLED, self.myLetterDoc.hasElement("Sender Address Repeated")) self.setControlProperty( - "chkUseSubject", PropertyNames.PROPERTY_ENABLED, + "chkUseSubject", PropertyNames.PROPERTY_ENABLED, self.myLetterDoc.hasElement("Subject Line")) self.setControlProperty( - "chkUseSigns", PropertyNames.PROPERTY_ENABLED, + "chkUseSigns", PropertyNames.PROPERTY_ENABLED, self.myLetterDoc.hasElement("Letter Signs")) self.myLetterDoc.updateDateFields() @@ -1065,28 +1065,28 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.addRoadmap() i = 0 i = self.insertRoadmapItem( - 0, True, + 0, True, self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_TYPESTYLE -1], LetterWizardDialogImpl.RM_TYPESTYLE) i = self.insertRoadmapItem( - i, False, + i, False, self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_BUSINESSPAPER - 1], LetterWizardDialogImpl.RM_BUSINESSPAPER) i = self.insertRoadmapItem( - i, True, + i, True, self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_ELEMENTS - 1], LetterWizardDialogImpl.RM_ELEMENTS) i = self.insertRoadmapItem( - i, True, - self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_SENDERRECEIVER - 1], + i, True, + self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_SENDERRECEIVER - 1], LetterWizardDialogImpl.RM_SENDERRECEIVER) i = self.insertRoadmapItem( i, False, self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_FOOTER -1], LetterWizardDialogImpl.RM_FOOTER) i = self.insertRoadmapItem( - i, True, - self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_FINALSETTINGS - 1], + i, True, + self.resources.RoadmapLabels[LetterWizardDialogImpl.RM_FINALSETTINGS - 1], LetterWizardDialogImpl.RM_FINALSETTINGS) self.setRoadmapInteractive(True) self.setRoadmapComplete(True) @@ -1105,8 +1105,8 @@ class LetterWizardDialogImpl(LetterWizardDialog): PathSelection(self.xMSF, self, PathSelection.TransferMode.SAVE, PathSelection.DialogTypes.FILE) self.myPathSelection.insert( - 6, 97, 70, 205, 45, self.resources.reslblTemplatePath_value, - True, HelpIds.getHelpIdString(HID + 47), + 6, 97, 70, 205, 45, self.resources.reslblTemplatePath_value, + True, HelpIds.getHelpIdString(HID + 47), HelpIds.getHelpIdString(HID + 48)) self.myPathSelection.sDefaultDirectory = self.sUserTemplatePath self.myPathSelection.sDefaultName = "myLetterTemplate.ott" @@ -1123,12 +1123,12 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.myConfig.readConfiguration(root, "cp_") self.mainDA.append( RadioDataAware.attachRadioButtons( - self.myConfig, "cp_LetterType", - (self.optBusinessLetter, self.optPrivOfficialLetter, + self.myConfig, "cp_LetterType", + (self.optBusinessLetter, self.optPrivOfficialLetter, self.optPrivateLetter), True)) self.mainDA.append( UnoDataAware.attachListBox( - self.myConfig.cp_BusinessLetter, "cp_Style", + self.myConfig.cp_BusinessLetter, "cp_Style", self.lstBusinessStyle, True)) self.mainDA.append( UnoDataAware.attachListBox( @@ -1136,7 +1136,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): self.lstPrivOfficialStyle, True)) self.mainDA.append( UnoDataAware.attachListBox( - self.myConfig.cp_PrivateLetter, "cp_Style", + self.myConfig.cp_PrivateLetter, "cp_Style", self.lstPrivateStyle, True)) self.mainDA.append( UnoDataAware.attachCheckBox( @@ -1193,7 +1193,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): cgl, "cp_PrintCompanyLogo", self.chkUseLogo, True)) self.businessDA.append( UnoDataAware.attachCheckBox( - cgl, "cp_PrintCompanyAddressReceiverField", + cgl, "cp_PrintCompanyAddressReceiverField", self.chkUseAddressReceiver, True)) self.businessDA.append( UnoDataAware.attachCheckBox( @@ -1220,7 +1220,7 @@ class LetterWizardDialogImpl(LetterWizardDialog): UnoDataAware.attachEditControl( cgl, "cp_Greeting", self.lstGreeting, True)) self.letterDA.append(RadioDataAware.attachRadioButtons( - cgl, "cp_SenderAddressType", + cgl, "cp_SenderAddressType", (self.optSenderDefine, self.optSenderPlaceholder), True)) self.businessDA.append( UnoDataAware.attachEditControl( diff --git a/wizards/com/sun/star/wizards/ui/event/DataAware.py b/wizards/com/sun/star/wizards/ui/event/DataAware.py index c2771d5a47c1..450d6f753dd5 100644 --- a/wizards/com/sun/star/wizards/ui/event/DataAware.py +++ b/wizards/com/sun/star/wizards/ui/event/DataAware.py @@ -30,7 +30,7 @@ class DataAware(object): def __init__(self, dataObject_, field_): self._dataObject = dataObject_ - self._field = field_ + self._field = field_ ''' sets the given value to the UI control diff --git a/wizards/com/sun/star/wizards/ui/event/UnoDataAware.py b/wizards/com/sun/star/wizards/ui/event/UnoDataAware.py index 7c3436caa59c..b117dcb4fa21 100644 --- a/wizards/com/sun/star/wizards/ui/event/UnoDataAware.py +++ b/wizards/com/sun/star/wizards/ui/event/UnoDataAware.py @@ -67,7 +67,7 @@ class UnoDataAware(DataAware): return UnoDataAware(data, prop, label, PropertyNames.PROPERTY_LABEL) @classmethod - def attachListBox(self, data, prop, listBox, field): + def attachListBox(self, data, prop, listBox, field): uda = UnoDataAware(data, prop, listBox, "SelectedItems", True) method = getattr(uda,"updateData") listBox.addItemListener(ItemListenerProcAdapter(method)) |