pl_editor: save comment associated to DS_DATA_ITEM graphic items.
The editor has an entry to set a comment associated to a graphic item. It is only for the designer, but the code to save it in .wks file when not empty was missing. The code to read it exists since the beginning, so no change in file format
This commit is contained in:
parent
16ebb3a433
commit
6b9e44e59c
|
@ -305,6 +305,9 @@ void DS_DATA_MODEL_IO::format( DS_DATA_ITEM_TEXT* aItem, int aNestLevel ) const
|
||||||
|
|
||||||
formatRepeatParameters( aItem );
|
formatRepeatParameters( aItem );
|
||||||
|
|
||||||
|
if( !aItem->m_Info.IsEmpty() )
|
||||||
|
m_out->Print( 0, " (comment %s)\n", m_out->Quotew( aItem->m_Info ).c_str() );
|
||||||
|
|
||||||
m_out->Print( 0, ")\n" );
|
m_out->Print( 0, ")\n" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -327,6 +330,9 @@ void DS_DATA_MODEL_IO::format( DS_DATA_MODEL* aModel, DS_DATA_ITEM* aItem, int a
|
||||||
|
|
||||||
formatRepeatParameters( aItem );
|
formatRepeatParameters( aItem );
|
||||||
|
|
||||||
|
if( !aItem->m_Info.IsEmpty() )
|
||||||
|
m_out->Print( 0, " (comment %s)\n", m_out->Quotew( aItem->m_Info ).c_str() );
|
||||||
|
|
||||||
m_out->Print( 0, ")\n" );
|
m_out->Print( 0, ")\n" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -348,6 +354,9 @@ void DS_DATA_MODEL_IO::format( DS_DATA_ITEM_POLYGONS* aItem, int aNestLevel ) co
|
||||||
if( aItem->m_LineWidth )
|
if( aItem->m_LineWidth )
|
||||||
m_out->Print( 0, " (linewidth %s)\n", double2Str( aItem->m_LineWidth ).c_str() );
|
m_out->Print( 0, " (linewidth %s)\n", double2Str( aItem->m_LineWidth ).c_str() );
|
||||||
|
|
||||||
|
if( !aItem->m_Info.IsEmpty() )
|
||||||
|
m_out->Print( 0, " (comment %s)\n", m_out->Quotew( aItem->m_Info ).c_str() );
|
||||||
|
|
||||||
// Write polygon corners list
|
// Write polygon corners list
|
||||||
for( int kk = 0; kk < aItem->GetPolyCount(); kk++ )
|
for( int kk = 0; kk < aItem->GetPolyCount(); kk++ )
|
||||||
{
|
{
|
||||||
|
@ -395,6 +404,9 @@ void DS_DATA_MODEL_IO::format( DS_DATA_ITEM_BITMAP* aItem, int aNestLevel ) cons
|
||||||
formatRepeatParameters( aItem );
|
formatRepeatParameters( aItem );
|
||||||
m_out->Print( 0,"\n");
|
m_out->Print( 0,"\n");
|
||||||
|
|
||||||
|
if( !aItem->m_Info.IsEmpty() )
|
||||||
|
m_out->Print( 0, " (comment %s)\n", m_out->Quotew( aItem->m_Info ).c_str() );
|
||||||
|
|
||||||
// Write image in png readable format
|
// Write image in png readable format
|
||||||
m_out->Print( aNestLevel, "(%s\n", getTokenName( T_pngdata ) );
|
m_out->Print( aNestLevel, "(%s\n", getTokenName( T_pngdata ) );
|
||||||
wxArrayString pngStrings;
|
wxArrayString pngStrings;
|
||||||
|
|
Loading…
Reference in New Issue