Objects¶
Comment¶
Obj¶
- class pdpy_lib.objects.obj.Obj(className=None, pd_lines=None, json=None, **kwargs)[source]¶
Bases:
ObjectThis class represents a Pure Data object.
- Parameters
className (
stringorNone) – The className of the pd object.pd_lines (
stringorNone) – The pd-lang line that represents the object, eg:#X obj 10 10 float 1json (
dictor None) – The json dictionary representing the object.**kwargs – Additional keyword arguments are passed
pdpy.Object
- Raises
ValueError – If the
pd_linesprovided invalid arguments
Msg¶
- class pdpy_lib.objects.msg.Msg(message=None, pd_lines=None, json=None)[source]¶
Bases:
ObjectRepresentation of a patchable Pd Message box
This class represents a Pd message box with a list of targets. Each
targetis an instance ofMessage.- Parameters
message (
str, alistofstr, orNone) – A string or a list of strings with a message. Each element of the list defaults to theoutlettarget.pd_lines (
str) – A pd-lang string with a message, eg:#X msg 10 10 Hello worldOr, for multiple targets:#X msg 10 10 Hello World \;pd quitjson (
dict) – A json dictionary with the scope of a Msg.
Gui Objects¶
- class pdpy_lib.objects.gui.Gui(pd_lines=None, json=None, **kwargs)[source]¶
Bases:
ObjectA Pd Native Gui object like
floatatom,symbolatom, orlistboxA Pd Native Gui object is a graphical user interface that is implemented in pure data.
- Parameters
pd_lines (
list) – The lines of the Pure Data patch that define the object.json (
dict) – A JSON representation of the object.**kwargs (optional) –
Keyword arguments are:
className: the name of the class of the objectdigits_width: The width of the object in digitsflag: The flag of the objectlabel: The label of the objectfontsize: The font-size of the object
Other keyword arguments are passed to
pdpy_lib.primitives.bounds.Boundsandpdpy_lib.patching.comm.Comm
See also
pdpy_lib.utilities.default.DefaultFor default parameters.