Hi, On 31.01.19 18:11, Simon Richter wrote:
>> I would prefer that we create a base units object and then derived >> application level units objects as needed. These objects would be >> small, compile quickly, and could be included in the common library so >> they are available everywhere. Using 1nm units for schematics doesn't >> make a lot of sense to me even if/when we do convert to 64 bit integers. > Hm, we could get most of that by making the unit conversion functions in > BASE_SCREEN abstract, which would already dynamically dispatch most of > the unit conversions. Okay, I've tried that, and the situation is not as good as I've expected — we have way too much code that doesn't have a SCREEN context and thus needs to pull the conversion factor out of the macro definition. I think it would be more work to pass the a screen reference (or a unit conversion object, so we can work without a screen) to all of these places than it would be to define a common conversion factor for everyone. Simon
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Mailing list: https://launchpad.net/~kicad-developers Post to : kicad-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~kicad-developers More help : https://help.launchpad.net/ListHelp