ags icon indicating copy to clipboard operation
ags copied to clipboard

letter-spacing does not work properly.

Open daricoder opened this issue 1 year ago • 2 comments

The CSS letter-spacing property adds spacing above and below when more than one word is used. If I remove the letter-spacing property, everything works correctly.

https://github.com/Aylur/dotfiles/assets/64455469/31b5d842-8c1c-4f0d-8fa3-7cb0bdcdf0fe

daricoder avatar Jan 22 '24 19:01 daricoder

No idea why it happens, It seems like to only happen if the label is set with Variable.bind, but if the variable changes value it works correctly after that, if I use .hook instead it seems to work

Label({
  label: 'test test', // works
  label: variable.bind() // causes the issue
  setup: self => self.hook(variable, () => {
    self.label = variable.value // seems to work
  })
})

Aylur avatar Jan 23 '24 17:01 Aylur

Yeap! it seems that the label widget has to be initialized with some value. Since if I use Widget.Label().bind() or hook() the problem also occurs but it is solved by initializing the label property. I also tried Widget.Label({setup: .....}) and it works only if the initialized label property is given to a value other than empty.

daricoder avatar Jan 24 '24 03:01 daricoder