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

hyphens:auto test #312

Closed
paulirish opened this Issue Jun 26, 2011 · 13 comments

Comments

Projects
None yet
5 participants
@paulirish
Member

paulirish commented Jun 26, 2011

i dont think this is high priority.. just wanted to write this down..

http://people.mozilla.org/~jkew/hyph.html (just has the moz prefixed version)

http://www.w3.org/TR/2011/WD-css3-text-20110412/#hyphens

it's available in safari nightly and in 5.1 (along with text-emphasis). but not any version of chrome.

it landed 12mo ago http://trac.webkit.org/changeset/61548

anyway a basic feature test will false positive in chrome, so it'll have to be a functional feature test... somehow... i have no idea.

maybe fixed width font and with hyphens text should only wrap to two lines but without hyphens it gets forced to three.. test the height of the box? fun!

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish
Member

paulirish commented Jun 26, 2011

demo thing from divya http://jsfiddle.net/nimbu/Rv6vV/

@NoNoNo

This comment has been minimized.

Show comment
Hide comment
@NoNoNo

NoNoNo Aug 1, 2011

I would like to see a Modernizr test that works with hyphenator as a yepnope fallback.

Some links:

Some caveats:

  • Chrome actually knows -webkit-hyphens but does no hyphenation
  • Some browsers only hyphenate text in the system language

NoNoNo commented Aug 1, 2011

I would like to see a Modernizr test that works with hyphenator as a yepnope fallback.

Some links:

Some caveats:

  • Chrome actually knows -webkit-hyphens but does no hyphenation
  • Some browsers only hyphenate text in the system language
@nwtn

This comment has been minimized.

Show comment
Hide comment
@nwtn

nwtn Aug 17, 2011

Contributor

I just posted at http://davidnewton.ca/the-current-state-of-hyphenation-on-the-web about this, with some proof-of-concept tests for Modernizr. Kinda hacky/needs some work, but it seems to be functioning at least.

https://github.com/nwtn/Modernizr/blob/master/feature-detects/hyphens.js

demo page: http://dev.davidnewton.ca/demos/hyphenation/test.html

Contributor

nwtn commented Aug 17, 2011

I just posted at http://davidnewton.ca/the-current-state-of-hyphenation-on-the-web about this, with some proof-of-concept tests for Modernizr. Kinda hacky/needs some work, but it seems to be functioning at least.

https://github.com/nwtn/Modernizr/blob/master/feature-detects/hyphens.js

demo page: http://dev.davidnewton.ca/demos/hyphenation/test.html

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Aug 18, 2011

Member

thx nwtn! i pulled your code in. :)

probably could clean this up some but this is good for now. nice research!

Member

paulirish commented Aug 18, 2011

thx nwtn! i pulled your code in. :)

probably could clean this up some but this is good for now. nice research!

@nwtn

This comment has been minimized.

Show comment
Hide comment
@nwtn

nwtn Aug 18, 2011

Contributor

sweet. could definitely use some cleanup, i agree. :)

Contributor

nwtn commented Aug 18, 2011

sweet. could definitely use some cleanup, i agree. :)

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Dec 10, 2011

Member

I filed crbug.com/107111 for chrome to stop exposing Hyphenation so we dont need this workaround.

Member

paulirish commented Dec 10, 2011

I filed crbug.com/107111 for chrome to stop exposing Hyphenation so we dont need this workaround.

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Dec 10, 2011

Member

I cleaned up @nwtn's hyphen tests a little in f56ddf7 and made the base hyphens:auto work like our other false-positiving tests do.

and more docs in 3f10031 (plus a code shift)

thx for those links before @NoNoNo .. super useful.

current result is here: https://github.com/Modernizr/Modernizr/blob/master/feature-detects/hyphens.js

We can close this ticket now.. I'm going to watch crbug.com/107111 and when that fix ships to stable Chrome me or @nwtn can remove the functional test .

Member

paulirish commented Dec 10, 2011

I cleaned up @nwtn's hyphen tests a little in f56ddf7 and made the base hyphens:auto work like our other false-positiving tests do.

and more docs in 3f10031 (plus a code shift)

thx for those links before @NoNoNo .. super useful.

current result is here: https://github.com/Modernizr/Modernizr/blob/master/feature-detects/hyphens.js

We can close this ticket now.. I'm going to watch crbug.com/107111 and when that fix ships to stable Chrome me or @nwtn can remove the functional test .

@paulirish paulirish closed this Dec 10, 2011

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Dec 10, 2011

Member

caniuse has a nice wrap-test that could use ElementFromPoint to detect: http://tests.caniuse.com/ thx @Fyrd

Member

paulirish commented Dec 10, 2011

caniuse has a nice wrap-test that could use ElementFromPoint to detect: http://tests.caniuse.com/ thx @Fyrd

@alexlande

This comment has been minimized.

Show comment
Hide comment
@alexlande

alexlande Dec 10, 2011

I wanted to give this a try and generated a custom build with the hyphen test. I'm getting no-workingcsshyphens in every browser, including Firefox and Safari.

The original demo by @nwtn applies workingcsshyphens in those browsers.

alexlande commented Dec 10, 2011

I wanted to give this a try and generated a custom build with the hyphen test. I'm getting no-workingcsshyphens in every browser, including Firefox and Safari.

The original demo by @nwtn applies workingcsshyphens in those browsers.

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Dec 10, 2011

Member

@lawnday, this isnt available in the custom builder just yet. You can try out the latest on the test suite: http://modernizr.github.com/Modernizr/test/index.html

Member

paulirish commented Dec 10, 2011

@lawnday, this isnt available in the custom builder just yet. You can try out the latest on the test suite: http://modernizr.github.com/Modernizr/test/index.html

@alexlande

This comment has been minimized.

Show comment
Hide comment
@alexlande

alexlande Dec 10, 2011

Ah, my mistake, thanks.

alexlande commented Dec 10, 2011

Ah, my mistake, thanks.

@ShaggyDude

This comment has been minimized.

Show comment
Hide comment
@ShaggyDude

ShaggyDude Jun 22, 2012

This is prob. not the place to ask but what is the status on chrome implementing hyphens?

ShaggyDude commented Jun 22, 2012

This is prob. not the place to ask but what is the status on chrome implementing hyphens?

@paulirish

This comment has been minimized.

Show comment
Hide comment
@paulirish

paulirish Jun 22, 2012

Member

what is the status on chrome implementing hyphens?

read and star this badboy: http://code.google.com/p/chromium/issues/detail?id=47083

Member

paulirish commented Jun 22, 2012

what is the status on chrome implementing hyphens?

read and star this badboy: http://code.google.com/p/chromium/issues/detail?id=47083

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