SetColumnOptions sets the main parameters for one column.
(column string, on bool, fixMin bool, min float32, fixMax bool, max float32)
| 177 | |
| 178 | // SetColumnOptions sets the main parameters for one column. |
| 179 | func (pl *PlotEditor) SetColumnOptions(column string, on bool, fixMin bool, min float32, fixMax bool, max float32) *ColumnOptions { |
| 180 | co := pl.ColumnOptions(column) |
| 181 | if co == nil { |
| 182 | slog.Error("plotcore.PlotEditor.SetColumnOptions: column not found", "column", column) |
| 183 | return nil |
| 184 | } |
| 185 | co.On = on |
| 186 | co.Range.FixMin = fixMin |
| 187 | if fixMin { |
| 188 | co.Range.Min = min |
| 189 | } |
| 190 | co.Range.FixMax = fixMax |
| 191 | if fixMax { |
| 192 | co.Range.Max = max |
| 193 | } |
| 194 | return co |
| 195 | } |
| 196 | |
| 197 | // SaveSVG saves the plot to an svg -- first updates to ensure that plot is current |
| 198 | func (pl *PlotEditor) SaveSVG(fname core.Filename) { //types:add |
nothing calls this directly
no test coverage detected