66
77== Intro
88
9- GStat is a python class used to send messages from LinuxCNC to other python programs.
9+ GStat is a Python class used to send messages from LinuxCNC to other Python programs.
1010It uses GObject to deliver messages, making it easy to listen for specific information.
1111This is referred to as event-driven programming, which is more efficient then every program
1212polling LinuxCNC at the same time.
@@ -81,17 +81,16 @@ GSTAT.forced_update()
8181
8282# loop till exit
8383try:
84- GLib.MainLoop().run()
84+ GLib.MainLoop().run()
8585except KeyboardInterrupt:
8686 raise SystemExit
8787----
8888
89- This would be loaded with 'loadusr python PATH-TO-FILE/FILENAME.py' +
90- or if you need to wait for the pins to be made before continuing: +
91- 'loadusr python -Wn metric_status PATH-TO-FILE/FILENAME.py' +
89+ This would be loaded with 'loadusr python PATH-TO-FILE/FILENAME.py' or if you need to wait for the pins to be made before continuing: +
90+ `loadusr python -Wn metric_status PATH-TO-FILE/FILENAME.py` +
9291The pins would be: 'metric_status.g20' and 'metric_status.g21'.
9392
94- === GladeVCP python extension code pattern
93+ === GladeVCP Python extension code pattern
9594
9695This file assumes there are three GTK labels named:
9796
@@ -134,9 +133,9 @@ def get_handlers(halcomp,builder,useropts):
134133 return [HandlerClass(halcomp,builder,useropts)]
135134----
136135
137- === QTVCP python extension code pattern
136+ === QtVCP Python extension code pattern
138137
139- Qtvcp extends GStat, so must be loaded differently but all the messages are available in Qtvcp . +
138+ QtVCP extends GStat, so must be loaded differently but all the messages are available in QtVCP . +
140139This handler file assumes there are three QLabels named:
141140
142141* 'state_label'
@@ -290,10 +289,10 @@ Linuxcnc does not update this for every type of line.
290289*tool-in-spindle-changed* :: '(returns integer)' -
291290Sent when the tool has changed.
292291
293- *tool-info-changed* :: '(returns python object)' -
292+ *tool-info-changed* :: '(returns Python object)' -
294293Sent when current tool info changes.
295294
296- *current-tool-offset* :: '(returns python object)' -
295+ *current-tool-offset* :: '(returns Python object)' -
297296Sent when the current tool offsets change.
298297
299298*motion-mode-changed* :: '(returns integer)' -
@@ -413,7 +412,7 @@ This depends on the widget/libraries used. +
413412intended to be sent when G-code is loaded. +
414413This depends on the widget/libraries used. +
415414
416- *graphics-view-changed* :: '(returns string, python Dict or None)' -
415+ *graphics-view-changed* :: '(returns string, Python dict or None)' -
417416intended to be sent when graphics view is changed. +
418417This depends on the widget/libraries used. +
419418
@@ -437,16 +436,16 @@ This depends on the widget/libraries used. +
437436intended to be sent when moving the cursor one line down in G-code display. +
438437This depends on the widget/libraries used. +
439438
440- *dialog-request* :: '(returns python dict)' -
439+ *dialog-request* :: '(returns Python dict)' -
441440intended to be sent when requesting a gui dialog. +
442- It uses a python dict for communication. +
441+ It uses a Python dict for communication. +
443442The dict must include the following keyname pair: +
444443* NAME: 'requested dialog name' +
445444 The dict usually has several keyname pairs - it depends on the dialog. +
446445 dialogs return information using a general message +
447446 This depends on the widget/libraries used. +
448447
449- *focus-overlay-changed* :: '(returns bool, string, python object)' -
448+ *focus-overlay-changed* :: '(returns bool, string, Python object)' -
450449intended to be sent when requesting an overlay to be put over the display. +
451450This depends on the widget/libraries used. +
452451
@@ -477,24 +476,24 @@ integer represents the kind of error. ERROR, TEXT or DISPLAY +
477476string is the actual error message. +
478477This depends on the widget/libraries used. +
479478
480- *general* :: '(returns python dict)' -
479+ *general* :: '(returns Python dict)' -
481480intended to be sent when message must be sent that is not covered by a more specific message. +
482481General message should be used a sparsely as reasonable because all object connected to it will have to parse it. +
483- It uses a python dict for communication. +
482+ It uses a Python dict for communication. +
484483The dict should include and be checked for a unique id keyname pair: +
485484* ID: 'UNIQUE_ID_CODE' +
486- The dict usually has more keyname pair - it depends on implementation. +
485+ The dict usually has more keyname pair - it depends on implementation. +
487486
488487*forced-update* :: '(returns None)' -
489488intended to be sent when one wishes to initialize or arbitrarily update an object. +
490489This depends on the widget/libraries used. +
491490
492- *progress* :: '(returns integer, python object)'
491+ *progress* :: '(returns integer, Python object)' -
493492intended to be sent to indicate the progress of a filter program. +
494493This depends on the widget/libraries used. +
495494
496- *following-error* :: '(returns python list)'
497- returns a list of all joints current following error +
495+ *following-error* :: '(returns Python list)' -
496+ returns a list of all joints current following error. +
498497
499498== Functions
500499
@@ -553,7 +552,7 @@ You must be in the proper mode to jog.
553552
554553*check_for_modes* :: '(mode)' -
555554This function checks for required LinuxCNC mode. +
556- It returns a python tuple (state, mode) +
555+ It returns a Python tuple (state, mode) +
557556mode will be set the mode the system is in +
558557state will set to: +
559558false if mode is 0 +
@@ -602,8 +601,7 @@ returns string representing the internal selected axis letter. +
602601
603602== Known Issues
604603
605- Some status points are reported wrongly during a running program. +
606- This is because the interpreter runs ahead of the current position of a running program. +
607- This will hopefully be resolved with the merge of state-tags branch. +
604+ Some status points are reported wrongly during a running program because the interpreter runs ahead of the current position of a running program.
605+ This will hopefully be resolved with the merge of state-tags branch.
608606
609607// vim: set syntax=asciidoc:
0 commit comments