Monday, 30 August 2010

Editing and Selection Code Separation

As NaroCAD internal changes are ongoing, they were targeting to minimize the relations between components. This simplify debugging as most components will be self-containing.
Selection code is smarter thanks to bxtrx changes but also is separated as an external component. This will mean mostly that selection information will be both better (the old code that you were able to detect the face under the "Solid selection mode" was buggy, and will work right now), and more bug-proof, as all actions (for example Fillet2D, which previously breaks the selection as this action does it by itself) will use an unified code. So less side effects and easier bug tracking and fixing in this area, if problems will arise.
An area that NaroCAD also will improve is the editing code that was "fragile". This was both because of selection code, a fairly complex case when more tools were mixed, like: floating toolbar, the inactive "none" action and the actual editing code.
As of today, the editing code will use the Selection component described above, and also will be separated from inactive action. So when you click on a shape to edit it, the "inactive mode" will become "editing mode" in code terms, so hopefully this harder to debug code will have less problems in future and will be also easier to maintain.
Those changes as a whole will slightly improve the quality of NaroCAD codebase, mostly in the more complex cases in our code-base. Also will make easier to export some actions/inputs to plugins as they have less dependencies and are easier to register.

No comments:

Post a Comment