go-streamdeck icon indicating copy to clipboard operation
go-streamdeck copied to clipboard

Word-wrap text

Open magicmonkey opened this issue 5 years ago • 4 comments

Currently text draws on a single line. Would be good to word-wrap it, although as it isn't a fixed-width font, this will involve some tricky maths.

magicmonkey avatar May 16 '20 20:05 magicmonkey

An interim solution for this is to let the user pass their own multi-line string as a slice

magicmonkey avatar May 17 '20 11:05 magicmonkey

Is this library still being maintained? If a PR is likely to be accepted, I'll spend a bit of time restoring backwards-compat

I've been working on adding support for multiline text (plus x and y margins, and also justification). I'm not sure a fully featured wordwrap is that useful given the very small dimensions. I chose to just allow \n in mulitline text, instead of passing a slice of strings.

(excuse the crappy iphone photo, I didn't feel like dumping the image for each button)

carpii avatar Jan 22 '23 01:01 carpii

Hi,

Looks great! In terms of being maintained, I personally don't use the library much, but I do still have a Streamdeck so I'll crunch through the PRs when I get a chance and get the library back up to date.

Thanks, Kevin

On Sun, 22 Jan 2023, at 1:00 AM, carpii wrote:

I've been working on adding support for multiline text (aswell as x and margins, and justification)

Is this library still being maintained? If a PR is likely to be accepted, I'll spend a bit of time restoring backwards-compat

(excuse the crappy iphone photo, I didn't feel like dumping the image for each button)

https://camo.githubusercontent.com/8efc2bb5f5a8d1a23111f238dd460846b83c4978e9828d1ab00fac7dfd18b24e/68747470733a2f2f692e696d6775722e636f6d2f466a50767178462e706e67

— Reply to this email directly, view it on GitHub https://github.com/magicmonkey/go-streamdeck/issues/6#issuecomment-1399369570, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABKETQCMFMKNJJQRB4JY73WTSBDTANCNFSM4NDB6GQA. You are receiving this because you authored the thread.Message ID: @.***>

magicmonkey avatar Jan 22 '23 10:01 magicmonkey

Thanks, that's good to know

I'll do a bit more testing and submit a PR

Cheers

carpii avatar Jan 22 '23 20:01 carpii