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

rotated text #57

Open
giko45 opened this issue Mar 29, 2018 · 1 comment
Open

rotated text #57

giko45 opened this issue Mar 29, 2018 · 1 comment
Labels
contribution Contributions that enhance the usage of this library

Comments

@giko45
Copy link

giko45 commented Mar 29, 2018

Hi,

in case anyone is interested in 90 deg rotated column headers:

change createElement
from
if (textContent != null) { e.textContent = textContent; }

to
if (textContent != null) { if (elementType == 'th') { e.innerHTML = '<div>'+textContent+'</div>'; } else { e.textContent = textContent; } }

and add following styles
`
th.pvtColLabel {
text-align: center;
white-space: nowrap;
vertical-align: middle;
width: 1.5em;
}
th.pvtColLabel div {
-moz-transform: rotate(-90.0deg); /* FF3.5+ /
-o-transform: rotate(-90.0deg); /
Opera 10.5 /
-webkit-transform: rotate(-90.0deg); /
Saf3.1+, Chrome /
filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0.083); /
IE6,IE7 /
-ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0.083)"; /
IE8 */
margin: 2em -6em 2em -6em;
}

`

@nagarajanchinnasamy
Copy link
Owner

Hi @giko45, Thanks for your contribution. 👍

@nagarajanchinnasamy nagarajanchinnasamy added the contribution Contributions that enhance the usage of this library label Apr 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution Contributions that enhance the usage of this library
Projects
None yet
Development

No branches or pull requests

2 participants