diff options
author | Hubert Hirtz <hubert@hirtzfr.eu> | 2020-08-16 17:34:28 +0200 |
---|---|---|
committer | Hubert Hirtz <hubert@hirtzfr.eu> | 2020-08-16 17:34:28 +0200 |
commit | 34e3264e22ba0524b124f4d350f154e276a7fee8 (patch) | |
tree | ebe755ad9c30eab81c82341f6f20e69e817d7d3d /config.go | |
parent | Fix +typing=active being sent incorrectly (diff) |
ui: Configurable nick column width
Diffstat (limited to 'config.go')
-rw-r--r-- | config.go | 17 |
1 files changed, 11 insertions, 6 deletions
@@ -7,18 +7,23 @@ import ( ) type Config struct { - Addr string - Nick string - Real string - User string - Password *string - Highlights []string + Addr string + Nick string + Real string + User string + Password *string + + Highlights []string + NickColWidth int `yaml:"nick-column-width"` Debug bool } func ParseConfig(buf []byte) (cfg Config, err error) { err = yaml.Unmarshal(buf, &cfg) + if cfg.NickColWidth <= 0 { + cfg.NickColWidth = 16 + } return } |