xmlTheme.go 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. package xlsx
  2. import "encoding/xml"
  3. // xlsxTheme directly maps the theme element in the namespace
  4. // http://schemas.openxmlformats.org/drawingml/2006/main -
  5. // currently I have not checked it for completeness - it does as much
  6. // as I need.
  7. type xlsxTheme struct {
  8. ThemeElements xlsxThemeElements `xml:"themeElements"`
  9. }
  10. // xlsxThemeElements directly maps the themeElements element in the namespace
  11. // http://schemas.openxmlformats.org/drawingml/2006/main -
  12. // currently I have not checked it for completeness - it does as much
  13. // as I need.
  14. type xlsxThemeElements struct {
  15. ClrScheme xlsxClrScheme `xml:"clrScheme"`
  16. }
  17. // xlsxClrScheme directly maps the clrScheme element in the namespace
  18. // http://schemas.openxmlformats.org/drawingml/2006/main -
  19. // currently I have not checked it for completeness - it does as much
  20. // as I need.
  21. type xlsxClrScheme struct {
  22. Name string `xml:"name,attr"`
  23. Children []xlsxClrSchemeEl `xml:",any"`
  24. }
  25. // xlsxClrScheme maps to children of the clrScheme element in the namespace
  26. // http://schemas.openxmlformats.org/drawingml/2006/main -
  27. // currently I have not checked it for completeness - it does as much
  28. // as I need.
  29. type xlsxClrSchemeEl struct {
  30. XMLName xml.Name
  31. SysClr *xlsxSysClr `xml:"sysClr"`
  32. SrgbClr *xlsxSrgbClr `xml:"srgbClr"`
  33. }
  34. // xlsxSysClr directly maps the sysClr element in the namespace
  35. // http://schemas.openxmlformats.org/drawingml/2006/main -
  36. // currently I have not checked it for completeness - it does as much
  37. // as I need.
  38. type xlsxSysClr struct {
  39. Val string `xml:"val,attr"`
  40. LastClr string `xml:"lastClr,attr"`
  41. }
  42. // xlsxSrgbClr directly maps the srgbClr element in the namespace
  43. // http://schemas.openxmlformats.org/drawingml/2006/main -
  44. // currently I have not checked it for completeness - it does as much
  45. // as I need.
  46. type xlsxSrgbClr struct {
  47. Val string `xml:"val,attr"`
  48. }