After creating a pg = wx.propgrid.PropertyGrid(…) I can access the string, which will be displayed, if a property has an unspecified value with pg.GetUnspecifiedValueText().
How would I set that to a different value, e.g. to '<Unspecified>'.
I tried
pg.SetUnspecifiedValueText('<Unspecified>') but get an AttributeError.
pg.UnspecifiedValue = '<Unspecified>' does not work either.
# To keep fore- and background color for cells with unspecified value, get the current appearance
cell = pg.GetUnspecifiedValueAppearance()
# Set the text
cell.SetText('<Unspecified>')
# Update the appearance
pg.SetUnspecifiedValueAppearance(cell)
I was disheartened to look into this method because I thought it is all about the appearance (colours, fonts, …) and not the text displayed.