Commit 4b212810 authored by charras's avatar charras

minor bugs fixed (including plot labels issues)

parent ceb1de9e
......@@ -126,6 +126,7 @@ SCH_TEXT* SCH_TEXT::GenCopy()
newitem->m_HJustify = m_HJustify;
newitem->m_VJustify = m_VJustify;
newitem->m_IsDangling = m_IsDangling;
newitem->m_Italic = m_Italic;
return newitem;
}
......
......@@ -262,7 +262,7 @@ void PlotLibPart( SCH_COMPONENT* DrawLibItem )
t1 ? TEXT_ORIENT_HORIZ : TEXT_ORIENT_VERT,
Text->m_Size,
GR_TEXT_HJUSTIFY_CENTER, GR_TEXT_VJUSTIFY_CENTER,
thickness);
thickness, false, true);
}
break;
......@@ -476,7 +476,7 @@ static void PlotTextField( SCH_COMPONENT* DrawLibItem,
orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ,
field->m_Size,
hjustify, vjustify,
thickness, field->m_Italic);
thickness, field->m_Italic, true);
}
else /* We plt the reference, for a multiple parts per package */
{
......@@ -683,12 +683,12 @@ void PlotTextStruct( EDA_BaseStruct* Struct )
PlotGraphicText( g_PlotFormat, wxPoint( pX - offset, pY ),
color, Text, TEXT_ORIENT_HORIZ, Size,
GR_TEXT_HJUSTIFY_RIGHT, GR_TEXT_VJUSTIFY_CENTER,
thickness, italic );
thickness, italic, true );
else
PlotGraphicText( g_PlotFormat, wxPoint( pX, pY - offset ),
color, Text, TEXT_ORIENT_HORIZ, Size,
GR_TEXT_HJUSTIFY_LEFT, GR_TEXT_VJUSTIFY_BOTTOM,
thickness, italic );
thickness, italic, true );
break;
case 1: /* Orientation vert UP */
......@@ -696,12 +696,12 @@ void PlotTextStruct( EDA_BaseStruct* Struct )
PlotGraphicText( g_PlotFormat, wxPoint( pX, pY + offset ),
color, Text, TEXT_ORIENT_VERT, Size,
GR_TEXT_HJUSTIFY_CENTER, GR_TEXT_VJUSTIFY_TOP,
thickness, italic );
thickness, italic, true );
else
PlotGraphicText( g_PlotFormat, wxPoint( pX - offset, pY ),
color, Text, TEXT_ORIENT_VERT, Size,
GR_TEXT_HJUSTIFY_RIGHT, GR_TEXT_VJUSTIFY_BOTTOM,
thickness, italic );
thickness, italic, true );
break;
case 2: /* Horiz Orientation - Right justified */
......@@ -709,12 +709,12 @@ void PlotTextStruct( EDA_BaseStruct* Struct )
PlotGraphicText( g_PlotFormat, wxPoint( pX + offset, pY ),
color, Text, TEXT_ORIENT_HORIZ, Size,
GR_TEXT_HJUSTIFY_LEFT, GR_TEXT_VJUSTIFY_CENTER,
thickness, italic );
thickness, italic, true );
else
PlotGraphicText( g_PlotFormat, wxPoint( pX, pY + offset ),
PlotGraphicText( g_PlotFormat, wxPoint( pX, pY - offset ),
color, Text, TEXT_ORIENT_HORIZ, Size,
GR_TEXT_HJUSTIFY_RIGHT, GR_TEXT_VJUSTIFY_BOTTOM,
thickness, italic );
thickness, italic, true );
break;
case 3: /* Orientation vert BOTTOM */
......@@ -722,12 +722,12 @@ void PlotTextStruct( EDA_BaseStruct* Struct )
PlotGraphicText( g_PlotFormat, wxPoint( pX, pY - offset ),
color, Text, TEXT_ORIENT_VERT, Size,
GR_TEXT_HJUSTIFY_CENTER, GR_TEXT_VJUSTIFY_BOTTOM,
thickness, italic );
thickness, italic, true );
else
PlotGraphicText( g_PlotFormat, wxPoint( pX + offset, pY ),
PlotGraphicText( g_PlotFormat, wxPoint( pX - offset, pY ),
color, Text, TEXT_ORIENT_VERT, Size,
GR_TEXT_HJUSTIFY_RIGHT, GR_TEXT_VJUSTIFY_TOP,
thickness, italic );
thickness, italic, true );
break;
}
......@@ -778,7 +778,7 @@ static void PlotSheetLabelStruct( Hierarchical_PIN_Sheet_Struct* Struct )
PlotGraphicText( g_PlotFormat, wxPoint( tposx, posy ), txtcolor,
Struct->m_Text, TEXT_ORIENT_HORIZ, wxSize( size, size ),
side, GR_TEXT_VJUSTIFY_CENTER,
thickness, italic );
thickness, italic, true );
/* dessin du symbole de connexion */
if( Struct->m_Edge )
......
......@@ -330,6 +330,9 @@ void WinEDA_MainFrame::OnOpenFileInTextEditor( wxCommandEvent& event )
wxFileDialog dlg( this, _( "Load File to Edit" ), wxGetCwd(),
wxEmptyString, mask,wxFD_OPEN );
if( dlg.ShowModal() == wxID_CANCEL )
return;
if( dlg.GetPath() && wxGetApp().GetEditorName() )
ExecuteFile( this, wxGetApp().GetEditorName(), dlg.GetPath() );
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment