垂直显示
回答
我相信你不得不使用的图像。可以在设计时创建,也可以在运行时使用HttpHandler生成图像,如果它们需要动态的话。使所有的字段都使用TemplateFields并将图像放在HeaderTemplate中。有点乏味,但这是我能想到的唯一方式。也许有些第三方网格控件可以处理这个问题。
Silverlight可以做到这一点(如能闪光,我敢肯定)。 CSS3将支持它。但图形文字是现在的方式。
您可以使用任何一种文本隐藏技术在CSS中显示访问浏览器的文本,但显示图形(文字垂直排列)为视力正常的用户。
Stu Nicholls有一个有趣的HTML/CSS技术,如果有点冗长的HTML。但是,它不会执行您要查找的单词轮换。只是抛出另一种选择。
如果你不介意的IE唯一的解决方案,你可以使用一些IE支持CSS过滤器。事情是这样的:
<div style="width:100%; filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);">
This text is rotated 90 degrees.
</div>
我使用下面的CSS做了IE尽管它可能仅限于浏览器,版本等..
写作模式:TB-RL; 过滤:flipv fliph
在IE7 +,你可以使用DX变换:
writing-mode: tb-rl;
filter: flipv fliph;
在旧IE(对可怜的灵魂还是坚持了下来):
filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);
在Safari /铬(基于webkit的任何东西)你可以使用变换:
-webkit-transform: rotate(270deg);
最新的FX版本有相当于:
-moz-transform: rotate(270deg);
但这还不是主流。
我一直在试图与图形文字要做到这一点,但有一个few problems。
我用了一个 休息(BR)命令每个字母
/*Do this in a loop for each header cell so Cells[0] to cells[however many] and however long the string is so use length properties to get the actual length of the text string */
protected void GridView1_SelectedIndexChanged(object sender, EventArgs e)
{
StringBuilder vtxt = new StringBuilder();
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(0,1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(1, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(2, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(3, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(4, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(5, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(6, 1));
vtxt.Append("<br />");
vtxt.Append(GridView1.HeaderRow.Cells[0].Text.ToString().Substring(7, 1));
GridView1.HeaderRow.Cells[2].Text = vtxt.ToString();
}
欢迎来到计算器!请提供上述代码的简短说明以提高帖子的准确性:) – 2012-10-20 13:38:07
- 1. 垂直ListView显示
- 2. 垂直显示列和行
- 3. 显示表格垂直
- 4. 在asp.net中以垂直方式显示数据和垂直显示
- 5. C#WPF垂直列表框不显示垂直滚动条
- 6. 如何垂直显示Android广告
- 7. 如何垂直显示记录?
- 8. 垂直显示GridView中的项目?
- 9. 列表框显示字符串垂直
- 10. 显示文本在框中间(垂直)
- 11. StatusBar垂直显示的项目
- 12. 显示横排垂直的SQL Server 2005
- 13. 按钮文字垂直显示
- 14. SQL查询来显示结果垂直
- 15. 垂直中间显示图像hover div
- 16. 垂直滚动条不显示
- 17. 显示HTML UL在垂直方向
- 18. 阵列显示垂直而非水平
- 19. 用divider垂直显示表格列android
- 20. 垂直文本显示在表TD中?
- 21. ListBox垂直滚动条不显示(WPF)
- 22. 显示垂直菜单css的问题
- 23. 在oracle中垂直显示结果
- 24. 垂直滚动条不显示
- 25. 列表视图,垂直显示文本
- 26. 显示图像悬停(垂直居中)
- 27. UWP垂直滚动条不显示
- 28. 垂直格式的显示号码
- 29. 垂直导航显示使用JQuery
- 30. 在交叉点上显示垂直线
我在联网系统中使用此之间,它似乎总是工作。 – Kezzer 2008-12-24 12:27:05