feat: add support for editing STEP headers
Fixes #2739 (closed)
I have made certain decisions to keep things simple.
- Certain STEP headers receive an array of strings as an input. Since we can't pass that kind of data structure in Gmsh options (DefaultOptions.h) I have opted to use a length 1 array. This works fine the STEP writer formats the output (max line width) anyway.
- I have chosen to leave the defaults empty so that they default to the OCC, however I am not sure if that is the best solution. When the user wants to intentionally set a header section as an empty string Gmsh will default to the OCC internal value. Maybe there is a better way to check if the options have been set other than
string.empty()
? - I used names for the options that match the definitions of the STEP fields in OCC. We could potentially change those to something more user friendly.
- I used
Handle_...
instead ofHandle(SomeType)
since it is less verbose (by 1 char). - I formatted the code with clang-format (and the committed config file). FYI we should probably set-up some pre-commit hooks for formatting, because there were other formatting issues from unrelated code that clang-format picked up.
Edited by Giannis Nikiteas