I'm using MissionControl on my backend and Ionosphere on the front end, so I'm fully Gantry-enabled.
I'd very much like to use the toggle element in my own backend components. I would like to do this in code, however, as my admin pages are all done in code and not using the Joomla elements system.
The closes I've come is this:
$p = new JParameter('');
$g = new JElementGantry($p);
$t = new JElementToggle();
$node = new GantrySimpleXMLElement('<yes></yes>');
echo $g->fetchElement('gn', 1, $node, 'cn');
echo $t->fetchElement('thename', 1, $node);
This draws the toggle, but it's not active, even though it appears that all of the JS and CSS are brought in via the use of JElementGantry().
I'm certain there's a proper way to do this, however.