Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Skia] TextBox doesn't follow WinUI TextWrapping #14708

Closed
morning4coffe-dev opened this issue Dec 5, 2023 · 6 comments
Closed

[Skia] TextBox doesn't follow WinUI TextWrapping #14708

morning4coffe-dev opened this issue Dec 5, 2023 · 6 comments
Labels
area/skia/text ✏️ area/skia ✏️ Categorizes an issue or PR as relevant to Skia difficulty/starter 🚀 Categorizes an issue for which the difficulty level is reachable by newcomers kind/bug Something isn't working project/input ⌨️ Categorizes an issue or PR as relevant to input (Button, CheckBox, Toggle, Scroll, Map, Numeric,...)

Comments

@morning4coffe-dev
Copy link
Member

Current behavior

I am getting different results with the same TextWrapping="Wrap" set on WinUI and Skia Gtk.

image

Expected behavior

The implementation should follow the WinUI counterpart

How to reproduce it (as minimally and precisely as possible)

<TextBox Height="120"
      TextWrapping="Wrap"/>

Workaround

No response

Works on UWP/WinUI

Yes

Environment

Uno.WinUI / Uno.WinUI.WebAssembly / Uno.WinUI.Skia

NuGet package version(s)

Latest Uno 5.0 and
<PackageVersion Include="Uno.WinUI" Version="5.1.0-dev.755" />

Affected platforms

Skia (WPF), Skia (GTK on Linux/macOS/Windows), Skia (Linux Framebuffer)

IDE

No response

IDE version

No response

Relevant plugins

No response

Anything else we need to know?

No response

@morning4coffe-dev morning4coffe-dev added kind/bug Something isn't working triage/untriaged Indicates an issue requires triaging or verification difficulty/tbd Categorizes an issue for which the difficulty level needs to be defined. labels Dec 5, 2023
@jeromelaban
Copy link
Member

jeromelaban commented Dec 5, 2023

Thanks. This is expected at this time and will evolve once #9417 improves.

@jeromelaban jeromelaban added the project/input ⌨️ Categorizes an issue or PR as relevant to input (Button, CheckBox, Toggle, Scroll, Map, Numeric,...) label Dec 5, 2023
@MartinZikmund MartinZikmund changed the title [Skia] TextBox doesn't follow WinUI TextWrapping [Skia] TextBox doesn't follow WinUI TextWrapping Jan 29, 2024
@MartinZikmund
Copy link
Member

Is this now working @ramezgerges ?

@MartinZikmund MartinZikmund added area/skia ✏️ Categorizes an issue or PR as relevant to Skia difficulty/starter 🚀 Categorizes an issue for which the difficulty level is reachable by newcomers area/skia/text ✏️ and removed triage/untriaged Indicates an issue requires triaging or verification difficulty/tbd Categorizes an issue for which the difficulty level needs to be defined. labels Jan 29, 2024
@ramezgerges
Copy link
Contributor

The repro is a little weird? If I'm guessing correctly, @morning4coffe-dev meant <TextBox Width="120" TextWrapping="Wrap"/> instead of <TextBox Height="120" TextWrapping="Wrap"/>. Anyway, Yeah, it's working. Not sure if we also need to fix this for the Gtk overlay version of the TextBox?

@jeromelaban
Copy link
Member

@ramezgerges if it's a small fix for gtk, let's fix it, otherwise, let's leave it.

@ramezgerges
Copy link
Contributor

It seems that we would need to change the Entry that we currently use to be a TextView, but that would also be somewhat buggy since it accepts multiline inputs when a TextBox shouldn't (by default), so we would also need to hack around that. The concept of a "TextBox that wraps but isn't multiline" isn't directly a thing in GTK as far as I can tell.

@ramezgerges ramezgerges removed their assignment Feb 21, 2024
@jeromelaban
Copy link
Member

Let's close this issue, we will not be fixing the GTK support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/skia/text ✏️ area/skia ✏️ Categorizes an issue or PR as relevant to Skia difficulty/starter 🚀 Categorizes an issue for which the difficulty level is reachable by newcomers kind/bug Something isn't working project/input ⌨️ Categorizes an issue or PR as relevant to input (Button, CheckBox, Toggle, Scroll, Map, Numeric,...)
Projects
None yet
Development

No branches or pull requests

4 participants