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

Soft hyphen not displayed at line break #1214

Closed
tomek1024 opened this issue Sep 16, 2020 · 11 comments
Closed

Soft hyphen not displayed at line break #1214

tomek1024 opened this issue Sep 16, 2020 · 11 comments
Labels
bug Existing features not working as expected

Comments

@tomek1024
Copy link

After @liZe suggestion in #1023 I'm opening a new issue for a missing hyphen on the end of the line.

After rendering https://zecer.elibri.com.pl/lte/unexpected-justification.html we get (should be "przysz-" at the end of the line)

image

System info:

> weasyprint -i
System: Linux
Machine: x86_64
Version: #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020
Release: 4.15.0-112-generic

WeasyPrint version: 51
Python version: 3.8.2
Cairo version: 11600
Pango version: 14407
CairoSVG version: 2.4.2
@liZe
Copy link
Member

liZe commented Sep 22, 2020

I don’t know why the soft hyphen is not displayed. As explained in #1023, it looks like a line break before the hyphen during the display. That’s really strange…

@liZe liZe added the bug Existing features not working as expected label Sep 22, 2020
@liZe liZe changed the title line break which shouldn't happen Soft hyphen not displayed at line break Sep 22, 2020
@malnajdi
Copy link
Contributor

@liZe This is using the latest master branch
image

@exploids
Copy link

exploids commented Jan 9, 2022

Is there any update on this? 😄

@liZe
Copy link
Member

liZe commented Jan 9, 2022

Is there any update on this? smile

Unfortunately no 😒.

@exploids
Copy link

exploids commented Jan 9, 2022

Interestingly when using the lang="xy" attribute and the hyphens: auto CSS property, the automatically inserted hyphens are rendered correctly.

Automatic hyphens:

<!DOCTYPE html>
<html lang="en">
	<p style="width: 3cm; background: yellow; hyphens: auto">
		Hippopotomonstrosesquippedaliophobia
	</p>
</html>

image

After inserting a soft hyphen:

<!DOCTYPE html>
<html lang="en">
	<p style="width: 3cm; background: yellow; hyphens: auto">
		Hippopo&shy;tomonstrosesquippedaliophobia
	</p>
</html>

image

@liZe
Copy link
Member

liZe commented Jan 25, 2022

I get the hyphen with your second example, that’s strange. Could you please give us more information about your system, including your version of Pango?

@liZe
Copy link
Member

liZe commented Jan 25, 2022

(And the original issue works too)

@exploids
Copy link

I'm using

OS: Fedora Linux 35 (Workstation Edition) x86_64
Kernel: 5.15.14-200.fc35.x86_64
DE: GNOME 41.3
WM: Mutter
Pango: 1.50.3-1.fc35

@grewn0uille
Copy link
Member

Hello!
This issue has been fixed by 424f080.

@alevals
Copy link

alevals commented May 18, 2022

@grewn0uille I'm still having the same issue with the latest release:

System: Linux
Machine: x86_64
Version: #1 SMP Mon Nov 8 10:21:19 UTC 2021
Release: 5.10.76-linuxkit

WeasyPrint version: 55.0
Python version: 3.9.2
Pydyf version: 0.1.2
Pango version: 14602

@grewn0uille
Copy link
Member

Hi @alevals!
Can you please share your HTML/CSS files?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Existing features not working as expected
Projects
None yet
Development

No branches or pull requests

6 participants