Fix encoding issues in Simulation Model dialog's property grid.

This commit is contained in:
Jeff Young 2022-11-07 14:45:51 +00:00
parent 672ce650a9
commit 095f02e6ef
2 changed files with 4 additions and 4 deletions

View File

@ -101,7 +101,7 @@ wxPGProperty* PGPropertyFactory( const PROPERTY_BASE* aProperty )
else if( typeId == TYPE_HASH( bool ) )
{
ret = new wxBoolProperty();
ret->SetAttribute( wxT( "UseCheckbox" ), true );
ret->SetAttribute( wxPG_BOOL_USE_CHECKBOX, true );
}
else if( typeId == TYPE_HASH( wxString ) )
{

View File

@ -812,13 +812,13 @@ wxPGProperty* DIALOG_SIM_MODEL<T>::newParamProperty( int aParamIndex ) const
break;
}
prop->SetAttribute( wxPG_ATTR_UNITS, param.info.unit );
prop->SetAttribute( wxPG_ATTR_UNITS, wxString::FromUTF8( param.info.unit.c_str() ) );
// Legacy due to the way we extracted the parameters from Ngspice.
if( param.isOtherVariant )
prop->SetCell( 3, wxString( param.info.defaultValueOfOtherVariant ) );
prop->SetCell( 3, wxString::FromUTF8( param.info.defaultValueOfOtherVariant ) );
else
prop->SetCell( 3, wxString( param.info.defaultValue ) );
prop->SetCell( 3, wxString::FromUTF8( param.info.defaultValue ) );
wxString typeStr;