• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

haiiliin / abqpy / 6433593370

06 Oct 2023 03:30PM UTC coverage: 73.825% (-9.3%) from 83.134%
6433593370

push

github

web-flow
[feature] Add GUI Toolkit Commands (backport #5260) (#5285)

[feature] Add GUI Toolkit Commands (#5260)

* Markdown

* Delete

* Add AFXApp and AFXBoolKeyword

* Delete

* Update headings

* Create parse.py

* Update parse.py

* Unicode Spaces

* Update .pre-commit-config.yaml

* Update md types

* Update Kernel plug-in registration commands.md

* Generated python stubs

* Add class inheritance

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Revert "Update .pre-commit-config.yaml"

This reverts commit 9d3aef3cc.

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix mypy errors

* Delete parse.py

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Fix return types and imports

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update AFXColumnItems.md

* Update abaqusGui.py

* Add class/global flags

* Delete flags.py

* Fix flags

* Fix

* Skip mypy

* Update abaqusGui.py

* Update constants.py

* Create kernelAccess.py

* Add plugin docs

* Revert changes by docformatter

* Delete markdown files

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
(cherry picked from commit a65ff5df8)

Co-authored-by: Hailin Wang <hailin.wang@connect.polyu.hk>

3661 of 3661 new or added lines in 151 files covered. (100.0%)

24137 of 32695 relevant lines covered (73.82%)

0.74 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/abaqus/PlugInRegistration/AFXOptionTreeList.py
1
from __future__ import annotations
×
2

3
from .AFXOptionTreeItem import AFXOptionTreeItem
×
4
from .constants import DEFAULT_SPACING
×
5
from .FXComposite import FXComposite
×
6
from .FXObject import FXObject
×
7
from .FXScrollWindow import FXScrollWindow
×
8

9

10
class AFXOptionTreeList(FXScrollWindow):
×
11
    """This class provides a scrolled list of groups of options that may be toggled on or off as a group or
12
    individually."""
13

14
    #: ID for the content window.
15
    ID_CONTENTS: int = hash("ID_CONTENTS")
×
16

17
    def __init__(
×
18
        self,
19
        p: FXComposite,
20
        nvis: int,
21
        opts: int = 0,
22
        x: int = 0,
23
        y: int = 0,
24
        w: int = 0,
25
        h: int = 0,
26
        pl: int = DEFAULT_SPACING,
27
        pr: int = DEFAULT_SPACING,
28
        pt: int = DEFAULT_SPACING,
29
        pb: int = DEFAULT_SPACING,
30
        hs: int = DEFAULT_SPACING,
31
        vs: int = DEFAULT_SPACING,
32
    ):
33
        """Constructor.
34

35
        Parameters
36
        ----------
37
        p : FXComposite
38
            Parent widget.
39
        nvis : int
40
            Number of visible items of list.
41
        opts : int
42
            Options and hints.
43
        x : int
44
            X coordinate of origin.
45
        y : int
46
            Y coordinate of origin.
47
        w : int
48
            Width of the widget.
49
        h : int
50
            Height of the widget.
51
        pl : int
52
            Left padding.
53
        pr : int
54
            Right padding.
55
        pt : int
56
            Top padding.
57
        pb : int
58
            Bottom padding.
59
        hs : int
60
            Horizontal spacing.
61
        vs : int
62
            Vertical spacing.
63
        """
64

65
    def addItemFirst(self, text: str, tgt: FXObject | None = None, msg: int = 0):
×
66
        """Adds a new item with the given text as the first item of the list.
67

68
        Parameters
69
        ----------
70
        text : str
71
            Item text.
72
        tgt : FXObject | None
73
            Item target.
74
        msg : int
75
            Item selector.
76
        """
77

78
    def addItemLast(self, text: str, tgt: FXObject | None = None, msg: int = 0):
×
79
        """Adds a new item with the given text as the last item of the list.
80

81
        Parameters
82
        ----------
83
        text : str
84
            Item text.
85
        tgt : FXObject | None
86
            Item target.
87
        msg : int
88
            Item selector.
89
        """
90

91
    def clearItems(self):
×
92
        """Removes all items from the list."""
93

94
    def computeItemHeight(self, p: AFXOptionTreeItem | None = None):
×
95
        """Computes the item size to be used as a base for default height computation.
96

97
        Parameters
98
        ----------
99
        p : AFXOptionTreeItem | None
100
            Item.
101
        """
102

103
    def createItem(self, text: str, tgt: FXObject, msg: int):
×
104
        """Creates a new tree item object.
105

106
        Parameters
107
        ----------
108
        text : str
109
            Item text.
110
        tgt : FXObject
111
            Item target.
112
        msg : int
113
            Item selector.
114
        """
115

116
    def getContentHeight(self):
×
117
        """Returns the content height.
118

119
        Reimplemented from FXScrollWindow.
120
        """
121

122
    def getContents(self):
×
123
        """Returns the content window."""
124

125
    def getContentWidth(self):
×
126
        """Returns the content width.
127

128
        Reimplemented from FXScrollWindow.
129
        """
130

131
    def getDefaultHeight(self):
×
132
        """Returns the default height.
133

134
        Reimplemented from FXScrollArea.
135
        """
136

137
    def getDefaultWidth(self):
×
138
        """Returns the default width.
139

140
        Reimplemented from FXScrollArea.
141
        """
142

143
    def getFirstItem(self):
×
144
        """Returns the first root item."""
145

146
    def getHSpacing(self):
×
147
        """Returns the horizontal inter-child spacing."""
148

149
    def getLastItem(self):
×
150
        """Returns the last root item."""
151

152
    def getNumItems(self):
×
153
        """Returns the number of top-level items."""
154

155
    def getNumVisible(self):
×
156
        """Returns the number of visible items."""
157

158
    def getPadBottom(self):
×
159
        """Returns the bottom padding."""
160

161
    def getPadLeft(self):
×
162
        """Returns the left padding."""
163

164
    def getPadRight(self):
×
165
        """Returns the right padding."""
166

167
    def getPadTop(self):
×
168
        """Returns the top padding."""
169

170
    def getVSpacing(self):
×
171
        """Returns the vertical inter-child spacing."""
172

173
    def layout(self):
×
174
        """Recalculates layout.
175

176
        Reimplemented from FXScrollWindow.
177
        """
178

179
    def moveContents(self, x: int, y: int):
×
180
        """Moves contents to the specified position.
181

182
        Parameters
183
        ----------
184
        x : int
185
            X location.
186
        y : int
187
            Y location
188
        """
189

190
    def removeItem(self, item: AFXOptionTreeItem):
×
191
        """Removes the given item from the list. This method does nothing if the given item does not exist.
192

193
        Parameters
194
        ----------
195
        item : AFXOptionTreeItem
196
            Item to be removed.
197
        """
198

199
    def setHSpacing(self, hs: int):
×
200
        """Sets the horizontal inter-child spacing.
201

202
        Parameters
203
        ----------
204
        hs : int
205
            Horizontal spacing.
206
        """
207

208
    def setNumVisible(self, nvis: int):
×
209
        """Sets the number of visible items.
210

211
        Parameters
212
        ----------
213
        nvis : int
214
            Number of visible items.
215
        """
216

217
    def setPadBottom(self, pb: int):
×
218
        """Sets the bottom padding.
219

220
        Parameters
221
        ----------
222
        pb : int
223
            Bottom padding.
224
        """
225

226
    def setPadLeft(self, pl: int):
×
227
        """Sets the left padding.
228

229
        Parameters
230
        ----------
231
        pl : int
232
            Left padding.
233
        """
234

235
    def setPadRight(self, pr: int):
×
236
        """Sets the right padding.
237

238
        Parameters
239
        ----------
240
        pr : int
241
            Right padding.
242
        """
243

244
    def setPadTop(self, pt: int):
×
245
        """Sets the top padding.
246

247
        Parameters
248
        ----------
249
        pt : int
250
            Top padding.
251
        """
252

253
    def setVSpacing(self, vs: int):
×
254
        """Sets the vertical inter-child spacing.
255

256
        Parameters
257
        ----------
258
        vs : int
259
            Vertical spacing.
260
        """
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc