This repository has been archived by the owner on Mar 4, 2023. It is now read-only.
/
PageSetupOptions.py
81 lines (71 loc) · 3.45 KB
/
PageSetupOptions.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
import typing
from abaqusConstants import *
class PageSetupOptions:
"""The PageSetupOptions object stores the settings that Abaqus uses when printing using a
Windows printer. The PageSetupOptions object has no constructor. Abaqus creates the
*pageSetupOptions* member when a session is started.
Notes
-----
This object can be accessed by:
.. code-block:: python
session.pageSetupOptions
"""
def setValues(
self,
imageSize: typing.Union[SymbolicConstant, float] = FIT_TO_PAGE,
units: SymbolicConstant = INCHES,
quality: SymbolicConstant = MEDIUM,
topMargin: float = 0,
bottomMargin: float = 0,
leftMargin: float = 0,
rightMargin: float = 0,
orientation: SymbolicConstant = PORTRAIT,
logo: Boolean = ON,
date: Boolean = ON,
):
"""This method modifies the PageSetupOptions object.
Parameters
----------
imageSize
A SymbolicConstant or a pair of Floats specifying the size of the printed image in the
currently selected units (inches or millimeters). Possible values are FIT_TO_PAGE and
SIZE_ON_SCREEN. The default value is FIT_TO_PAGE.Note:The minimum value of width and
height (*minWidth* and *minHeight*) is 10 mm (approximately 0.4 inches).
units
A SymbolicConstant specifying the units to use for the margins and image size. Possible
values are INCHES and MM. The default value is INCHES.
quality
A SymbolicConstant specifying the quality of the image. Possible values are COARSE,
MEDIUM, and FINE. The default value is MEDIUM.
topMargin
A Float specifying the top margin of the paper in the currently selected units (inches
or millimeters). Possible values are *topMargin* ≥≥ 0. The default value is 0.5.
bottomMargin
A Float specifying the bottom margin of the paper in the currently selected units
(inches or millimeters). Possible values are *bottomMargin* ≥≥ 0. The default value is
0.5.
leftMargin
A Float specifying the left margin of the paper in the currently selected units (inches
or millimeters). Possible values are *leftMargin* ≥≥ 0. The default value is 0.5.
rightMargin
A Float specifying the right margin of the paper in the currently selected units (inches
or millimeters). Possible values are *rightMargin* ≥≥ 0. The default value is 0.5.
orientation
A SymbolicConstant specifying the orientation of the image. Possible values are PORTRAIT
and LANDSCAPE. The default value is PORTRAIT.
logo
A Boolean specifying whether the output includes the Abaqus logo. The default value is
ON.
date
A Boolean specifying whether the output includes the date. The default value is ON.
Raises
------
RangeError
Note:The minimum value of width and height (*minWidth* and *minHeight*) is 10 mm
(approximately 0.4 inches).
- If *leftMargin* + *rightMargin* is out of range:
RangeError: leftMargin and rightMargin must produce image width >= minWidth
- If *topMargin* + *bottomMargin* is out of range:
RangeError: topMargin and bottomMargin must produce image height >= minHeight
"""
pass