Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
64077517
Commit
64077517
authored
Mar 22, 2011
by
Dick Hollenbeck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
revised bug fix
parent
ba6100e3
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
13 deletions
+11
-13
string.cpp
common/string.cpp
+2
-2
sch_sheet_pin.cpp
eeschema/sch_sheet_pin.cpp
+3
-5
sch_sweet_parser.cpp
new/sch_sweet_parser.cpp
+4
-4
class_pcb_text.cpp
pcbnew/class_pcb_text.cpp
+2
-2
No files found.
common/string.cpp
View file @
64077517
...
...
@@ -58,7 +58,7 @@ std::string EscapedUTF8( const wxString& aString )
std
::
string
ret
;
//
ret += '"';
ret
+=
'"'
;
for
(
std
::
string
::
const_iterator
it
=
utf8
.
begin
();
it
!=
utf8
.
end
();
++
it
)
{
...
...
@@ -77,7 +77,7 @@ std::string EscapedUTF8( const wxString& aString )
ret
+=
*
it
;
}
//
ret += '"';
ret
+=
'"'
;
return
ret
;
}
...
...
eeschema/sch_sheet_pin.cpp
View file @
64077517
...
...
@@ -241,8 +241,9 @@ bool SCH_SHEET_PIN::Save( FILE* aFile ) const
type
=
'U'
;
break
;
}
if
(
fprintf
(
aFile
,
"F%d
\"
%s
\"
%c %c %-3d %-3d %-3d
\n
"
,
m_Number
,
TO_UTF8
(
m_Text
),
type
,
side
,
m_Pos
.
x
,
m_Pos
.
y
,
if
(
fprintf
(
aFile
,
"F%d %s %c %c %-3d %-3d %-3d
\n
"
,
m_Number
,
EscapedUTF8
(
m_Text
).
c_str
(),
// supplies wrapping quotes
type
,
side
,
m_Pos
.
x
,
m_Pos
.
y
,
m_Size
.
x
)
==
EOF
)
{
return
false
;
...
...
@@ -298,9 +299,6 @@ bool SCH_SHEET_PIN::Load( LINE_READER& aLine, wxString& aErrorMsg )
m_Text
=
FROM_UTF8
(
name
);
m_Text
=
m_Text
.
AfterFirst
(
wxChar
(
'"'
)
);
m_Text
=
m_Text
.
BeforeLast
(
wxChar
(
'"'
)
);
if
(
size
==
0
)
size
=
DEFAULT_SIZE_TEXT
;
...
...
new/sch_sweet_parser.cpp
View file @
64077517
...
...
@@ -341,7 +341,7 @@ void SWEET_PARSER::parseFont( GR_FONT* me )
# that time FONT will have to be defined. Initially, only the font size and
# style are required. Italic and bold styles are optional. The font size
# height and width are in units yet to be determined.
(font [FONT] (size HEIGHT WIDTH) [
ITALIC] [BOLD
])
(font [FONT] (size HEIGHT WIDTH) [
italic] [bold
])
*/
...
...
@@ -426,8 +426,8 @@ void SWEET_PARSER::parsePin( PIN* me )
(pin TYPE SHAPE
(at X Y [ANGLE])
(length LENGTH)
(name NAME (font [FONT] (size HEIGHT WIDTH) [
ITALIC] [BOLD
])(visible YES))
(number NUMBER (font [FONT] (size HEIGHT WIDTH) [
ITALIC] [BOLD
] (visible YES))
(name NAME (font [FONT] (size HEIGHT WIDTH) [
italic] [bold
])(visible YES))
(number NUMBER (font [FONT] (size HEIGHT WIDTH) [
italic] [bold
] (visible YES))
(visible YES)
)
*/
...
...
@@ -911,7 +911,7 @@ void SWEET_PARSER::parseText( GR_TEXT* me )
# Valid horizontal justification values are center, right, and left. Valid
# vertical justification values are center, top, bottom.
(justify HORIZONTAL_JUSTIFY VERTICAL_JUSTIFY)
(font [FONT] (size HEIGHT WIDTH) [
ITALIC] [BOLD
])
(font [FONT] (size HEIGHT WIDTH) [
italic] [bold
])
(visible YES)
(fill FILL_TYPE)
)
...
...
pcbnew/class_pcb_text.cpp
View file @
64077517
...
...
@@ -163,9 +163,9 @@ bool TEXTE_PCB::Save( FILE* aFile ) const
wxString
txt
=
list
->
Item
(
ii
);
if
(
ii
==
0
)
fprintf
(
aFile
,
"Te
\"
%s
\"
\n
"
,
EscapedUTF8
(
txt
).
c_str
()
);
fprintf
(
aFile
,
"Te
%s
\n
"
,
EscapedUTF8
(
txt
).
c_str
()
);
else
fprintf
(
aFile
,
"nl
\"
%s
\"\n
"
,
TO_UTF8
(
txt
)
);
fprintf
(
aFile
,
"nl
%s
\n
"
,
EscapedUTF8
(
txt
).
c_str
(
)
);
}
delete
list
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment