Inspector: handle bad properties/values

Avoids a few exceptions which can occur when selecting widgets and properties in inspector.