style

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ValignTop    = 1
	ValignMiddle = 2
	ValignBottom = 3
	AlignLeft    = 4
	AlignCenter  = 5
	AlignRight   = 6
)

Variables

View Source
var (
	ColorSenColumnLine = Color{
		R: 153,
		G: 186,
		B: 174,
	}

	ColorTableLine = Color{
		R: 0,
		G: 0,
		B: 0,
	}

	ColorGray = Color{
		R: 211,
		G: 211,
		B: 211,
	}

	ColorHeatAlert = Color{
		R: 255,
		G: 179,
		B: 167,
	}
	ColorCoolAlert = Color{
		R: 152,
		G: 185,
		B: 255,
	}

	ColorWhite = Color{
		R: 255,
		G: 255,
		B: 255,
	}

	ColorBlack = ColorTableLine
)
View Source
var (
	ColorMax = Color{
		R: 40,
		G: 116,
		B: 172,
		A: 255,
	}

	ColorMin = Color{
		R: 40,
		G: 172,
		B: 96,
		A: 255,
	}

	ColorAvg = Color{
		R: 172,
		G: 40,
		B: 50,
		A: 255,
	}

	DefaultDialySensorStyle = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     111,
			RowColumnNumber: 5,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorBlack,
					},
					W:          12,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMax,
					},
					W:          32,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorAvg,
					},
					W:          32,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMin,
					},
					W:          32,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultWeeklySensorStyle = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     138,
			RowColumnNumber: 4,
			PageRowNumber:   3,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorBlack,
					},
					W:          30,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMax,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorAvg,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMin,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultMonthlySensorStyle = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     138,
			RowColumnNumber: 4,
			PageRowNumber:   8,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorBlack,
					},
					W:          30,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMax,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorAvg,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMin,
					},
					W:          36,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultYearlySensorStyle = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     185,
			RowColumnNumber: 3,
			PageRowNumber:   2,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorBlack,
					},
					W:          12,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMax,
					},
					W:          55,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorAvg,
					},
					W:          55,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMin,
					},
					W:          55,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultWeeklySensorV2Style = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     138,
			RowColumnNumber: 1,
			PageRowNumber:   4,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorBlack,
					},
					W:          20,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMax,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorAvg,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMin,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultDialySensorV2Style = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     138,
			RowColumnNumber: 4,
			PageRowNumber:   4,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorBlack,
					},
					W:          20,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMax,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorAvg,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMin,
					},
					W:          38,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultYearlySensorV2Style = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     180,
			RowColumnNumber: 2,
			PageRowNumber:   3,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorBlack,
					},
					W:          35,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMax,
					},
					W:          45,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorAvg,
					},
					W:          45,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 8,
						Color:    ColorMin,
					},
					W:          45,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}

	DefaultMonthlySensorV2Style = &SensorReportStyle{
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorBlack,
			},
			BackGround: Color{
				R: 223,
				G: 210,
				B: 151,
			},
			TextAlign: "right",
		},
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color:    ColorBlack,
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		TableStyle: TableStyle{
			Header: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				BackGround: ColorWhite,
			},
			ColumnWidth:     180,
			RowColumnNumber: 8,
			PageRowNumber:   3,
			Data: []TextBlockStyle{
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorBlack,
					},
					W:          20,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "left",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMax,
					},
					W:          50,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorAvg,
					},
					W:          50,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
				{
					TextStyle: TextStyle{
						Font:     "tw-r",
						FontSize: 10,
						Color:    ColorMin,
					},
					W:          50,
					H:          10.0,
					BackGround: ColorWhite,
					TextAlign:  "right",
				},
			},
		},
	}
)
View Source
var (
	SensorV3Style = SensorV3ReportStyle{
		Header: TextStyle{
			Font:     "tw-r",
			FontSize: 20,
			Color:    ColorBlack,
		},
		Title: TextStyle{
			Font:     "tw-m",
			FontSize: 16,
			Color:    ColorBlack,
		},
		SubTitle: TextStyle{
			Font:     "tw-r",
			FontSize: 9,
			Color: Color{
				R: 104,
				G: 104,
				B: 104,
			},
		},
		Page: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color: Color{
				R: 170,
				G: 170,
				B: 170,
			},
		},
		SectionBlock: TextBlockStyle{
			TextStyle: TextStyle{
				Font:     "tw-m",
				FontSize: 14,
				Color:    ColorWhite,
			},
			BackGround: Color{
				R: 99,
				G: 147,
				B: 141,
			},
		},
		SenColumn: TextStyle{
			Font:     "tw-r",
			FontSize: 14,
			Color: Color{
				R: 80,
				G: 124,
				B: 118,
			},
		},
		SenColumnLine: ColorSenColumnLine,
		Content: TextStyle{
			Font:     "tw-r",
			FontSize: 12,
			Color: Color{
				R: 38,
				G: 38,
				B: 38,
			},
		},
		TableDesc: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorBlack,
		},
		TableDescMax: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMax,
		},
		TableDescMin: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorMin,
		},
		TableDescAvg: TextStyle{
			Font:     "tw-r",
			FontSize: 8,
			Color:    ColorAvg,
		},
		StateTableStyle: StateTableStyle{
			MaxRowCount:      35,
			HeaderBackground: ColorGray,
			ColumnState: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 10,
					Color:    ColorBlack,
				},
				W:          85,
				BackGround: ColorWhite,
			},
			ColumnTime: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 10,
					Color:    ColorBlack,
				},
				W:          100,
				BackGround: ColorWhite,
			},
		},
		TableStyle: FixRowColumnTableStyle{
			ChartHeader: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 10,
					Color:    ColorBlack,
				},
				W:          40,
				BackGround: ColorWhite,
			},
			RowHeader: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          40,
				BackGround: ColorGray,
			},
			ColumnHeader: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          75,
				BackGround: ColorGray,
			},
			Content: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          75,
				BackGround: ColorWhite,
			},
			HeatAlertContent: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          75,
				BackGround: ColorHeatAlert,
			},
			CoolAlertContent: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          75,
				BackGround: ColorCoolAlert,
			},
			BlankContent: TextBlockStyle{
				TextStyle: TextStyle{
					Font:     "tw-r",
					FontSize: 8,
					Color:    ColorBlack,
				},
				W:          75,
				BackGround: ColorGray,
			},
		},
	}
)

Functions

This section is empty.

Types

type Color

type Color struct {
	R, G, B, A uint8
}

type FixRowColumnTableStyle

type FixRowColumnTableStyle struct {
	ChartHeader      TextBlockStyle
	RowHeader        TextBlockStyle
	ColumnHeader     TextBlockStyle
	Content          TextBlockStyle
	HeatAlertContent TextBlockStyle
	CoolAlertContent TextBlockStyle
	BlankContent     TextBlockStyle
}

type SensorReportStyle

type SensorReportStyle struct {
	Title        TextStyle      // 報表抬頭
	SubTitle     TextStyle      // 副標題
	SectionBlock TextBlockStyle // 區塊文字
	Content      TextStyle
	TableDesc    TextStyle
	TableDescMax TextStyle
	TableDescMin TextStyle
	TableDescAvg TextStyle
	TableStyle   TableStyle
}

type SensorV3ReportStyle

type SensorV3ReportStyle struct {
	Header          TextStyle
	Title           TextStyle      // 報表抬頭
	SubTitle        TextStyle      // 副標題
	SectionBlock    TextBlockStyle // 區塊文字
	Content         TextStyle
	TableDesc       TextStyle
	TableDescMax    TextStyle
	TableDescMin    TextStyle
	TableDescAvg    TextStyle
	StateTableStyle StateTableStyle
	TableStyle      FixRowColumnTableStyle
	SenColumn       TextStyle
	SenColumnLine   Color
	Page            TextStyle
}

type StateTableStyle

type StateTableStyle struct {
	ColumnTime       TextBlockStyle
	ColumnState      TextBlockStyle
	HeaderBackground Color
	MaxRowCount      int
}

type TableStyle

type TableStyle struct {
	Header          TextBlockStyle
	ColumnWidth     float64
	RowColumnNumber int
	PageRowNumber   int
	Data            []TextBlockStyle
}

type TextBlockStyle

type TextBlockStyle struct {
	TextStyle
	BackGround Color
	W, H       float64
	TextAlign  string
}

func (*TextBlockStyle) GetAlign

func (tbs *TextBlockStyle) GetAlign() int

type TextStyle

type TextStyle struct {
	Font     string
	FontSize int
	Color    Color
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL