[PD] help needed: "conditional" help patches

IOhannes m zmoelnig zmoelnig at iem.at
Mon Dec 11 15:43:10 CET 2023


On 12/11/23 15:29, Christof Ressi wrote:
> Ok, I have a come up with the following solution: I moved the 
> multichannel section into a dedicated patch and open it with [;pd open 
> <name> <dir> 1( when the user clicks a bang button in the main help 
> patch. It's not perfect, but kind of works for my purposes.

so the user only gets the error if they click on the bang?
hmm.

> 
> I am still wondering if anyone has run into the same issue and found 
> other solutions.


i don't, but here's my thoughts:

- i think class_sethelpsymbol() is evil in practically all cases (that 
do not deal with names that cannot be represented as filenames; and even 
these cases some hexmunging might be a better solution than 
class_sethelpsymbol())
- personally i wouldn't care to much about error messages in help 
patches (as in: going through hoops in order to avoid them). since in 
this case you control the actual error message make sure that it is 
friendly enough (e.g. just telling people that they will need a newer 
version of Pd in order to use this cool feature) - i strongly believe 
that we can expect people to actually read and understand an error 
message (and not just seek help just because "lines were red"). it's not 
that Pd's error messages are very obtrusive)

if you absolutely insist on not having error messages and do not share 
my aversion against class_sethelpsymbol() you could create two help 
patches and in the multichannel version *only* document the multichannel 
features and include the non-multichannel help patch as an ordinary 
object (probably with some "auto open" code. that way you wouldn't have 
to duplicate the common documentation.

mhdgs
IOhannes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20231211/56e8e17c/attachment-0001.sig>


More information about the Pd-list mailing list