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

Button wrapText property #1014

Closed
enchev opened this issue Nov 2, 2015 · 12 comments
Closed

Button wrapText property #1014

enchev opened this issue Nov 2, 2015 · 12 comments
Assignees
Milestone

Comments

@enchev
Copy link
Contributor

enchev commented Nov 2, 2015

https://gist.github.com/jbristowe/0d3ef7c9214e82487b52

@enchev enchev added the feature label Nov 2, 2015
@enchev enchev self-assigned this Nov 2, 2015
@enchev enchev added this to the 1.5 milestone Nov 2, 2015
@enchev enchev added the done label Nov 2, 2015
@enchev enchev closed this as completed Nov 2, 2015
@ligaz
Copy link
Contributor

ligaz commented Nov 2, 2015

Will this work from CSS as well?

@toddanglin
Copy link

Wow! What speed. Looking forward to 1.5. 💯

@enchev
Copy link
Contributor Author

enchev commented Nov 3, 2015

@ligaz Unfortunately no. We've still not decided how to implement this properly since the property is available only on some of the components. We have other similar scenarios not implemented as well.

@enchev
Copy link
Contributor Author

enchev commented Nov 3, 2015

@ligaz I spoke to soon. Actually we have such properties (font-* for example) and we can implement wrapping as well. The question here however will be should we add word-wrap or text-wrap?

@ligaz
Copy link
Contributor

ligaz commented Nov 3, 2015

I think text-wrap is deprecated.

@enchev
Copy link
Contributor Author

enchev commented Nov 4, 2015

Ok. Here is the issue: #1034

@ligaz
Copy link
Contributor

ligaz commented Nov 5, 2015

👍

@enchev
Copy link
Contributor Author

enchev commented Nov 9, 2015

Hey folks,

It seems that word-wrap is not what we want. Our Button wrapText property will simply tell if the button title will wrap or not while with CSS word-wrap you can specify if you can break word when wrapping not switching on/off the wrap itself. There is better property for this in CSS: white-space.

What do you think? How we should implement properly wrap on/off with CSS?

Thanks!

@bundyo
Copy link
Contributor

bundyo commented Nov 9, 2015

I think you can implement white-space: nowrap and normal in CSS, maybe with the difference that in NativeScript buttons the default value to be nowrap contrary to HTML which wraps everything by default. I wonder if you can also implement default stylesheets and just place the default value of button wrapping there.

The word-wrap CSS property for HTML is to specify how exactly the text wraps but is not intended to stop it from wrapping.

@ligaz
Copy link
Contributor

ligaz commented Nov 9, 2015

👍 for default stylesheets.

@enchev
Copy link
Contributor Author

enchev commented Nov 9, 2015

Thanks @bundyo! In this case I will rename this issue to Support CSS white-space: nowrap and normal.

@lock
Copy link

lock bot commented Aug 30, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Aug 30, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants