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

Strange behavior of WordWrap if there is a "/" symbol in the middle of a word. #448

Open
4 tasks done
IshmaZX82 opened this issue Feb 19, 2025 · 0 comments
Open
4 tasks done

Comments

@IshmaZX82
Copy link

Prerequisites

  • I have written a descriptive issue title
  • I have verified that I am running the latest version of Fonts
  • I have verified if the problem exist in both DEBUG and RELEASE mode
  • I have searched open and closed issues to ensure it has not already been reported

Fonts version

2.1.2

Other Six Labors packages and versions

SixLabors.ImageSharp.Drawing 2.1.5, SixLabors.ImageSharp 3.1.6

Environment (Operating system, version and so on)

Windows 11

.NET Framework version

.Net 8

Description

I noticed strange behavior of WordWrap if there is a "/" symbol in the middle of a word.
For example, if you output the text string "aaaaa bbbbb/ccccc ddddd" with a width limitation.
The picture on the left shows the expected behavior (as in GDI, GDI+, Wpf, Word, Chrome, etc.), on the right is the result obtained:

Image

Note: if there is only one long word in the line, in the middle of which there is a "/" symbol, then this is the correct behavior.
But if there is more than one word, then it should be wrapped entirely.

Steps to Reproduce

Draw text string "aaaaa bbbbb/ccccc ddddd" with a width limitation.

Images

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant