code cleanup
authorClaus Gittinger <cg@exept.de>
Mon, 16 Apr 2007 13:05:29 +0200
changeset 10510 f404894c7ea2
parent 10509 1c17129cf670
child 10511 7a6490a1af87
code cleanup
AbstractOperatingSystem.st
--- a/AbstractOperatingSystem.st	Wed Apr 11 12:30:51 2007 +0200
+++ b/AbstractOperatingSystem.st	Mon Apr 16 13:05:29 2007 +0200
@@ -5847,10 +5847,11 @@
 
 paperSizeNames
     |codes|
-codes := self paperSizeNumberToNameTable values asSortedCollection:[:a :b | a < b].
-^codes collect:[:each | self paperSizeNameForNumber: each]
+    codes := self paperSizeNumberToNameTable values asSortedCollection:[:a :b | a < b].
+    ^codes collect:[:each | self paperSizeNameForNumber: each]
 
     "Created: / 31-07-2006 / 15:35:36 / fm"
+    "Modified: / 16-04-2007 / 12:03:55 / cg"
 !
 
 paperSizeNumberForName:aName
@@ -6050,20 +6051,22 @@
 !
 
 collate: aBoolean
-|integer|
-integer:= aBoolean 
-            ifTrue:[1]  "DMCOLLATE_TRUE"
-            ifFalse:[0].  "DMCOLLATE_FALSE"
-self documentProperties collate: integer
+    |integer|
+
+    integer:= aBoolean 
+                ifTrue:[1]      "DMCOLLATE_TRUE"
+                ifFalse:[0].    "DMCOLLATE_FALSE"
+    self documentProperties collate: integer
 
     "Created: / 01-08-2006 / 09:56:01 / fm"
+    "Modified: / 16-04-2007 / 12:01:30 / cg"
 !
 
 comment
-
-^self printerInfo2 pComment
+    ^self printerInfo2 pComment
 
     "Created: / 01-08-2006 / 15:06:20 / fm"
+    "Modified: / 16-04-2007 / 12:01:42 / cg"
 !
 
 copies
@@ -6077,10 +6080,10 @@
 !
 
 copies: anInteger
-
-self documentProperties copies: anInteger
+    self documentProperties copies: anInteger
 
     "Created: / 31-07-2006 / 13:54:55 / fm"
+    "Modified: / 16-04-2007 / 12:01:48 / cg"
 !
 
 documentProperties
@@ -6100,30 +6103,33 @@
 
 driverName
 
-^self attributes at:#driverName
+    ^self attributes at:#driverName
 
     "Created: / 01-08-2006 / 15:33:08 / fm"
+    "Modified: / 16-04-2007 / 12:01:53 / cg"
 !
 
 location
 
-^self printerInfo2 pLocation
+    ^self printerInfo2 pLocation
 
     "Created: / 01-08-2006 / 15:06:28 / fm"
+    "Modified: / 16-04-2007 / 12:02:07 / cg"
 !
 
 longName
-    ^attributes at:#longName
-                ifAbsent:['']
+    ^attributes at:#longName ifAbsent:['']
 
     "Created: / 28-07-2006 / 12:06:32 / fm"
+    "Modified: / 16-04-2007 / 12:02:11 / cg"
 !
 
 medium
 
-^self attributes at:#medium
+    ^self attributes at:#medium
 
     "Created: / 01-08-2006 / 15:34:26 / fm"
+    "Modified: / 16-04-2007 / 12:02:14 / cg"
 !
 
 orientation
@@ -6150,9 +6156,10 @@
 
 pDriverName
 
-^self printerInfo2 pDriverName
+    ^self printerInfo2 pDriverName
 
     "Created: / 01-08-2006 / 15:33:08 / fm"
+    "Modified: / 16-04-2007 / 12:02:21 / cg"
 !
 
 paperSize
@@ -6211,25 +6218,25 @@
 !
 
 remotePrinterHost
-    ^attributes at:#remotePrinterHost
-                ifAbsent:['']
+    ^attributes at:#remotePrinterHost ifAbsent:['']
 
     "Created: / 28-07-2006 / 16:30:13 / fm"
+    "Modified: / 16-04-2007 / 12:02:32 / cg"
 !
 
 remotePrinterName
-    ^attributes at:#remotePrinterName
-                ifAbsent:['']
+    ^attributes at:#remotePrinterName ifAbsent:['']
 
     "Created: / 28-07-2006 / 16:30:06 / fm"
+    "Modified: / 16-04-2007 / 12:03:23 / cg"
 !
 
 status
-
-self isAvailable ifFalse:[^''].
-^self class statusNumberToDescriptionForNumber: self getPrinterInfo2 status
+    self isAvailable ifFalse:[^''].
+    ^self class statusNumberToDescriptionForNumber: self getPrinterInfo2 status
 
     "Created: / 01-08-2006 / 13:48:58 / fm"
+    "Modified: / 16-04-2007 / 12:03:41 / cg"
 !
 
 userFriendlyName
@@ -6243,13 +6250,19 @@
 !AbstractOperatingSystem::PrinterInfo methodsFor:'dc creation'!
 
 createDC
-
-     ^OperatingSystem createPrinterDC:self driverName 
-                        device:self printerName 
+     |driverName printerName|
+
+     driverName := self driverName.
+     printerName := self printerName.
+     Transcript show:driverName; show:' '; showCR:printerName.
+
+     ^OperatingSystem createPrinterDC:driverName 
+                        device:printerName 
                         output:self medium 
                         initData:self documentProperties.
 
     "Created: / 02-08-2006 / 16:51:02 / fm"
+    "Modified: / 16-04-2007 / 11:56:48 / cg"
 ! !
 
 !AbstractOperatingSystem::PrinterInfo methodsFor:'dialogs'!
@@ -6278,24 +6291,27 @@
 !AbstractOperatingSystem::PrinterInfo methodsFor:'modifying'!
 
 setLandscapeOrientation
-"DMORIENT_LANDSCAPE = 2"
-self documentProperties orientation: 2
+    "DMORIENT_LANDSCAPE = 2"
+    self documentProperties orientation: 2
 
     "Created: / 28-07-2006 / 15:53:35 / fm"
+    "Modified: / 16-04-2007 / 12:03:30 / cg"
 !
 
 setNumberOfCopies: n
 
-self documentProperties copies: n
+    self documentProperties copies: n
 
     "Created: / 28-07-2006 / 16:04:04 / fm"
+    "Modified: / 16-04-2007 / 12:03:33 / cg"
 !
 
 setPortraitOrientation
-"DMORIENT_PORTRAIT = 1"
-self documentProperties orientation: 1
+    "DMORIENT_PORTRAIT = 1"
+    self documentProperties orientation: 1
 
     "Created: / 28-07-2006 / 15:49:45 / fm"
+    "Modified: / 16-04-2007 / 12:03:36 / cg"
 ! !
 
 !AbstractOperatingSystem::PrinterInfo methodsFor:'printing & storing'!
@@ -6312,7 +6328,8 @@
 
 getDocumentProperties
     "Returns a aDevModeStructure"
- |h devMode |
+
+    |h devMode |
 
      h := OperatingSystem openPrinter: self printerName.
      devMode := OperatingSystem getDocumentProperties:nil
@@ -6323,6 +6340,7 @@
 
     "Created: / 28-07-2006 / 11:49:33 / fm"
     "Modified: / 31-07-2006 / 10:33:04 / fm"
+    "Modified: / 16-04-2007 / 12:02:00 / cg"
 !
 
 getPrinterInfo2
@@ -6360,9 +6378,10 @@
 
 isAvailable
 
-^self documentProperties notNil
+    ^self documentProperties notNil
 
     "Created: / 31-07-2006 / 13:08:58 / fm"
+    "Modified: / 16-04-2007 / 12:02:05 / cg"
 ! !
 
 !AbstractOperatingSystem::TimeInfo methodsFor:'accessing'!
@@ -6499,7 +6518,7 @@
 !AbstractOperatingSystem class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/AbstractOperatingSystem.st,v 1.166 2007-04-04 14:30:04 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/AbstractOperatingSystem.st,v 1.167 2007-04-16 11:05:29 cg Exp $'
 ! !
 
 AbstractOperatingSystem initialize!