Segment message panel infromation improvements.
* Make "Drawing" string translatable. * Add segment length to message panel. * Add segment angle to message panel.
This commit is contained in:
parent
9245b90392
commit
71e5fb13e6
|
@ -317,7 +317,7 @@ void DRAWSEGMENT::GetMsgPanelInfo( std::vector< MSG_PANEL_ITEM >& aList )
|
|||
|
||||
wxASSERT( m_Parent );
|
||||
|
||||
msg = wxT( "DRAWING" );
|
||||
msg = _( "Drawing" );
|
||||
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Type" ), msg, DARKCYAN ) );
|
||||
|
||||
|
@ -340,7 +340,18 @@ void DRAWSEGMENT::GetMsgPanelInfo( std::vector< MSG_PANEL_ITEM >& aList )
|
|||
break;
|
||||
|
||||
default:
|
||||
{
|
||||
aList.push_back( MSG_PANEL_ITEM( shape, _( "Segment" ), RED ) );
|
||||
|
||||
msg = ::CoordinateToString( GetLineLength( m_Start, m_End ) );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Length" ), msg, DARKGREEN ) );
|
||||
|
||||
// angle counter-clockwise from 3'o-clock
|
||||
const double deg = RAD2DEG( atan2( m_Start.y - m_End.y,
|
||||
m_End.x - m_Start.x ) );
|
||||
msg.Printf( wxT( "%.1f" ), deg );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Angle" ), msg, DARKGREEN ) );
|
||||
}
|
||||
}
|
||||
|
||||
wxString start;
|
||||
|
|
|
@ -280,17 +280,15 @@ void EDGE_MODULE::GetMsgPanelInfo( std::vector< MSG_PANEL_ITEM >& aList )
|
|||
if( !board )
|
||||
return;
|
||||
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Graphic Item" ), wxEmptyString, DARKCYAN ) );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Module" ), module->GetReference(), DARKCYAN ) );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Value" ), module->GetValue(), BLUE ) );
|
||||
msg.Printf( wxT( "%8.8lX" ), module->GetTimeStamp() );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "TimeStamp" ), msg, BROWN ) );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Mod Layer" ),
|
||||
module->GetLayerName(), RED ) );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Seg Layer" ),
|
||||
GetLayerName(), RED ) );
|
||||
msg = ::CoordinateToString( m_Width );
|
||||
aList.push_back( MSG_PANEL_ITEM( _( "Width" ), msg, BLUE ) );
|
||||
|
||||
// append the features shared with the base class
|
||||
DRAWSEGMENT::GetMsgPanelInfo( aList );
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue