Fix the longstanding bugs in Dynamic Components

I’ve made several Dynamic Components, and all of them have been an unnecessarily difficult struggle with the quirks and outright bugs in the current implementation of them. I’ve even given up on several when the difficulties became too great to fix, or didn’t seem worth the effort to develop workarounds.

Numerous individual examples have been highlighted before in the Dynamic Component section of this forum.

The ones that I’ve hit a wall with in my current attempt concerns the wildly inconsistent behaviour of DCs when the model units are not inches.

In particular, I’ve just been trying to create one, conceptually identical in principle to a picket fence, to use millimetres or even centimetres as input and display units, but with the intention of it being usable whatever the user’s model units, either metric or imperial.

I set all the parent component input parameters (Component Options) to Text input, User can edit as a textbox, and Display in model units.

It simply wouldn’t work with model units set to mm, ignoring the input of (say) 10mm and treating it as 10cm.

Now with model units set to centimetres, I get the following incomprehensible result when trying to create a DC for a model railway harbour wall, to simulate corrugated sheet metal piling. I have (among others) inputs in Component Options for PilingHeight, PileSpacing, and Edging height.


Harbour wall DC.skp (1.2 MB)

I have inputs in cm for these three values, they are correctly displayed in the Component Attributes converted to inches, but drawn scaled down by a factor of 2.54 - the ‘inch’ sizes are draw as cm.

For example, PilingHeight input as 5cm, correctly converting in Component Attributes to 1.9685… inches, but drawn as 1.97cm and shown as that size by both the Dimension tool and the Tape Measure.

Even if I change the PilingHeight to Decimal Number as the input type, and Redraw the component, it STILL comes out as 1.97cm, not 1.97 inches or the asked-for 5cm.

I can’t see any way of fixing this in my formulae. The DC simply does NOT do ‘what it says on the tin’.

Since I believe that people HAVE got DCs to work in either metric or imperial units, I suppose there must be some way round this. But it is TOO DIFFICULT for even a bright-ish PhD like me.

1 Like

In my view it’s simply not worth it. I’d say, deprecate DC and create something new from scratch.

Indeed, that might be better. Might even be easier.

It might become a full parametric method of drawing.

Perhaps even a simple update to the parametric.rb support file shipped with the SU Shapes plugin could be enough. It’s main drawback is that there is simply no way of ordering its parameters. If that were fixed, it would deal on it’s own with a lot of the things DCs now do.

Web and HTML dialogs are still VASTLY too complex for simple things.

For simple things I use ruby input box. not very complicated.

I do too, though they too are buggy on Mac - text labels are truncated unless you play games with lots of added spaces.

The parametric.rb Ruby allows you to edit parameters on the fly and redraw in place at any time, via a context menu.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.