[rkward-devel] Dependencies and 'about' information for plugins

Thomas Friedrichsmeier thomas.friedrichsmeier at ruhr-uni-bochum.de
Tue Feb 19 15:30:28 UTC 2013


Hi,

On Monday 18 February 2013, meik michalke wrote:
> > >   - rk.XML.switch()

[...]

> i've simplified it now, but it's a little different from what you suggested:

[...]

> i preferred it this way because it's a little more consistent with the
> output, especially since "standard" is supposed only to be valid for
> <case> nodes (therefore i'd find "standard=TRUE/FALSE" to indicate
> <true/false> nodes a bit confusing). it's a bit more to write for <case>
> stuff, but at the same time, the original intention of a plugin author is
> documented.
> 
> what do you think?

Looks good to me. Note that the original reason to have four different tags - 
true, false, case, default - as child elements of the switch is simply that 
there is no good way in an XML argument, to differentiate the string "TRUE" 
from a logical TRUE, or an empty string from "nothing". But your points about 
readability and consistency are quite valid.

> the <optionset> docs do also still need more examples.

Ok, optionset next. I tried translating the first optionset example from the 
"primary" documentation into rkwarddev. This is what I got:

firstname <- rk.XML.input ("Given name(s)")
lastname <- rk.XML.input ("Family name")
genderselect <- rk.XML.radio ("Gender", options = list ("Male"=c(val="m"), 
Female=c(val="f")))

rk.XML.optionset (
	content = list (rk.XML.optiondisplay (), rk.XML.row (firstname, lastname, 
genderselect)),
	optioncolumn = list (
		rk.XML.optioncolumn("firstnames", connect=firstname, modifier="text"),
		rk.XML.optioncolumn("lastnames", connect=lastname, 
modifier="text"),
		rk.XML.optioncolumn("genders", connect=genderselect)
	)
)

Perhaps you want to add this as a code example. The generated code was correct 
for this. I did not test extensively, beyond this. However, I did try a few of 
parameters, and the ones I tested worked correctly, too.

Regards
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/rkward-devel/attachments/20130219/da051499/attachment.sig>


More information about the Rkward-devel mailing list