Skip to content

Improve vtkSMProperty::CreateNewPrettyLabel behavior

NicolasB requested to merge nicolasB/paraview:fix-prettylabels into master

vtkSMProperty::CreateNewPrettyLabel(const char*) has two problems:

  • when encountering names with multiple uppercase letters at the beginning of its argument, it will introduce a wrong space (eg: FLUENTRenderCore should become FLUENTRender Core but becomes F LUENTRender Core).
  • when encountering acronyms followed by words, words will not be split (which is normal according to the current intended behavior) (eg: FLUENTRenderCore should better become FLUENT Render Core but would become FLUENTRender Core).

With this MR:

  • Multiple uppercase at the beginning of the name does not create an incorrect space between first and second letter anymore.
  • The method now splits better the name to also split words following multiple uppercase letters.

This issue is related to #21578 (closed) .

Fix: #21578 (closed)

Edited by NicolasB

Merge request reports