I'm struggling with text alignment in Firefox
What follows is Firefox's rendering of the page I'm struggling with in it's entirety. If you fix the path's to the ActiveWidget runtime you'll see what I'm struggling with... the text doesn't line up properly... there's a gap in each cell at the top and the left. Nothing I've done so far seems to overcome this. This is my biggest irritation (it's fine in IE). Could someone help me figure out a work around? Additional problems (using 2.0 RC1) with Firefox:
1) Mousewheel doesn't function unless I'm hovering the mouse directly over the scrollbars.
2) I still can't set the column header height without making the grid scroll endlessly. If you undo the commented line you'll see what I mean when you scroll.
1) Mousewheel doesn't function unless I'm hovering the mouse directly over the scrollbars.
2) I still can't set the column header height without making the grid scroll endlessly. If you undo the commented line you'll see what I mean when you scroll.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
<HEAD>
<title>Status</title>
<meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
<meta name="CODE_LANGUAGE" Content="C#">
<meta name="vs_defaultClientScript" content="JavaScript">
<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
<script src="../ActiveWidgetsRuntime/lib/aw.js"></script>
<link href="../ActiveWidgetsRuntime/styles/xp/aw.css" rel="stylesheet">
<style>
.aw-grid-control {height: 100%; width: 100%; margin: 0; border: none; font: menu; font-size: 12px; background-color: #E0DFE3}
.aw-column-0 {width: 125px; text-align:center;}
.aw-column-1 {width: 125px; text-align:center;}
.aw-column-2 {width: 125px; text-align:center;}
.aw-column-3 {width: 125px; text-align:center;}
.aw-column-4 {width: 125px; text-align:center;}
.aw-column-5 {width: 125px; text-align:center;}
.aw-column-6 {width: 125px; text-align:center;}
.aw-column-7 {width: 125px; text-align:center;}
.aw-column-8 {width: 125px; text-align:center;}
.aw-column-9 {width: 125px; text-align:center;}
.aw-column-10 {width: 125px; text-align:center;}
.aw-grid-headers {color: blue;}
.aw-grid-row {height: 50px;}
.aw-grid-cell {border-right: 1px solid threedlightshadow;}
.aw-grid-row {border-bottom: 1px solid threedlightshadow;}
.aw-rows-selected {background: #316ac5;}
.aw-mouseover-row .aw-row-selector {color: red;}
</style>
</HEAD>
<body onresize=ResizeGridDiv() onload=ResizeGridDiv()>
<form name="Form1" method="post" action="Status.aspx" id="Form1">
<input type="hidden" name="__VIEWSTATE" value="dDwtNjU0MzcyMTk1Ozs+d3UJulz2gArFM+uQ4mjy1EB5Lx4=" />
<center>
<div class="scrollTable" id="scrollTable" style="overflow: auto; height: 450; width: 95%;">
<script>
var myData = [["RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>8/20/2005<BR>7:08 PM","Unconfigured<BR>8/16/2005<BR>10:00 PM","Unconfigured<BR>NEVER","Unconfigured<BR>10/11/2005<BR>4:05 PM","Unconfigured<BR>10/13/2005<BR>4:13 PM","DDI<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>10/11/2005<BR>4:43 PM"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>NEVER","Unconfigured<BR>8/20/2005<BR>7:08 PM","Unconfigured<BR>9/16/2005<BR>6:33 PM","Unconfigured<BR>9/15/2005<BR>1:06 PM","DDI<BR>10/18/2005<BR>7:47 PM","Unconfigured<BR>9/24/2005<BR>6:14 PM","DDI<BR>10/17/2005<BR>8:37 PM","Unconfigured<BR>9/29/2005<BR>4:34 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>9/29/2005<BR>4:34 PM"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>11/29/2005<BR>2:28 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","DDI<BR>11/29/2005<BR>2:49 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","DDI<BR>11/4/2005<BR>11:28 AM","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","DDI<BR>11/4/2005<BR>11:22 AM"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","DDI<BR>12/8/2005<BR>11:25 AM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","DDI<BR>12/8/2005<BR>11:32 AM","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>12/8/2005<BR>11:26 AM","Unconfigured<BR>NEVER"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>NEVER","DDI<BR>11/9/2005<BR>2:02 PM","Unconfigured<BR>NEVER","DDI<BR>11/9/2005<BR>10:16 AM","DDI<BR>11/18/2005<BR>10:17 AM","Unconfigured<BR>NEVER","DDI<BR>11/9/2005<BR>11:09 AM","DDI<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>11/9/2005<BR>4:14 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>NEVER","DDI<BR>11/9/2005<BR>2:02 PM","Unconfigured<BR>NEVER","DDI<BR>11/9/2005<BR>10:16 AM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","DDI<BR>11/9/2005<BR>11:09 AM","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>11/9/2005<BR>3:33 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","DDI<BR>12/7/2005<BR>10:31 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","DDI<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","RSS Manager<BR>2/6/2006<BR>4:45 PM","DDI<BR>1/13/2006<BR>10:01 PM","DDI<BR>12/19/2005<BR>10:01 PM"],["RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","RSS Manager<BR>2/6/2006<BR>4:45 PM","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER"],["Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER","Unconfigured<BR>NEVER"]];
var myColumns = ["7DayWeather","Announcements","BusinessNews","EntertainmentNews","Events","LocalNews","NationalNews","ReplacementImages","SportsNews","Stocks","Weather","WhateverNews","WorldNews"];
var myRows = ["Charlotte1","Charlotte2","Gateway","IJL","ImageBuilder","Phil's Group","Phil2","RHG","rhgtesting","Test Group 2"];
var obj = new AW.Grid.Extended;
obj.setFixedLeft(0);
obj.getRowTemplate().setClass("text", "wrap");
obj.setRowCount(10);
obj.setColumnCount(13);
obj.setCellText(myData);
//obj.setHeaderHeight("30");
obj.setHeaderText(myColumns);
obj.getHeadersTemplate().setClass("text", "wrap");
obj.setSelectorVisible(true);
obj.setSelectorText(myRows);
obj.setSelectorWidth(120);
obj.setSelectionMode("single-cell");
obj.setCellEditable(false);
obj.defineCellProperty("color", function(col,row){
var value = this.getCellText(col,row);
var color = "black";
if (value.indexOf("NEVER") > 0){
color = "red";
}
else{
var today=new Date();
var index=value.indexOf("<BR>")+4;
var datepart=value.substring(index);
datepart = datepart.replace("<BR>", " ");
var then=new Date(datepart);
var hours=Math.ceil((((today.getTime()-then.getTime())/1000)/60)/60);
if (hours>24){
color="orange";
}
else if (hours>12){
color="blue";
}
}
return color;
});
obj.getCellTemplate().setStyle("color", function(){return this.getControlProperty("color"); });
//obj.onCellClicked = function(event, column, row){ window.status = "Cell " + column + "." + row + " clicked"};
document.write(obj);
</script>
</div>
</center>
</form>
<script language="javascript">
function ResizeGridDiv() {
var winW = 630, winH = 460;
if (parseInt(navigator.appVersion)>3) {
if (navigator.appName=="Netscape") {
winW = window.innerWidth;
winH = window.innerHeight;
}
if (navigator.appName.indexOf("Microsoft")!=-1) {
winW = document.body.offsetWidth;
winH = document.body.offsetHeight;
}
}
//window.status = winW + "." + winH;
if (winW < 800) {
document.getElementById("scrollTable").style.height=280;
}
else if (winW < 1024) {
document.getElementById("scrollTable").style.height=380;
}
else {
document.getElementById("scrollTable").style.height=500;
}
}
</script>
</body>
</HTML>
Matt Philmon
February 6,