mirror of
https://github.com/fumiama/go-docx.git
synced 2026-06-11 19:10:24 +08:00
make lint happy
This commit is contained in:
@@ -92,7 +92,7 @@ func (r *Run) AddTab() *Run {
|
|||||||
// Font sets the font of the run
|
// Font sets the font of the run
|
||||||
func (r *Run) Font(ascii, hansi, hint string) *Run {
|
func (r *Run) Font(ascii, hansi, hint string) *Run {
|
||||||
r.RunProperties.Fonts = &RunFonts{
|
r.RunProperties.Fonts = &RunFonts{
|
||||||
Ascii: ascii,
|
ASCII: ascii,
|
||||||
HAnsi: hansi,
|
HAnsi: hansi,
|
||||||
Hint: hint,
|
Hint: hint,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ func (r *RunProperties) UnmarshalXML(d *xml.Decoder, start xml.StartElement) err
|
|||||||
// RunFonts specifies the fonts used in the text of a run.
|
// RunFonts specifies the fonts used in the text of a run.
|
||||||
type RunFonts struct {
|
type RunFonts struct {
|
||||||
XMLName xml.Name `xml:"w:rFonts,omitempty"`
|
XMLName xml.Name `xml:"w:rFonts,omitempty"`
|
||||||
Ascii string `xml:"w:ascii,attr,omitempty"`
|
ASCII string `xml:"w:ascii,attr,omitempty"`
|
||||||
HAnsi string `xml:"w:hAnsi,attr,omitempty"`
|
HAnsi string `xml:"w:hAnsi,attr,omitempty"`
|
||||||
Hint string `xml:"w:hint,attr,omitempty"`
|
Hint string `xml:"w:hint,attr,omitempty"`
|
||||||
}
|
}
|
||||||
@@ -195,7 +195,7 @@ func (f *RunFonts) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
|
|||||||
for _, attr := range start.Attr {
|
for _, attr := range start.Attr {
|
||||||
switch attr.Name.Local {
|
switch attr.Name.Local {
|
||||||
case "ascii":
|
case "ascii":
|
||||||
f.Ascii = attr.Value
|
f.ASCII = attr.Value
|
||||||
case "hAnsi":
|
case "hAnsi":
|
||||||
f.HAnsi = attr.Value
|
f.HAnsi = attr.Value
|
||||||
case "hint":
|
case "hint":
|
||||||
|
|||||||
Reference in New Issue
Block a user