c-smile / sciter-sdk

Sciter is an embeddable HTML/CSS/scripting engine
http://sciter.com
Other
2.11k stars 224 forks source link

a question of vlist #4

Closed gxlmyacc closed 8 years ago

gxlmyacc commented 8 years ago

Hi, Andrew, Here is my code: <html> <head> <style> @import url(vgrid.css);

table { style-set: vgrid; 
        width:*;
        height:*; } 
table th { width:200px; }

th[fixed], td[fixed] {
  position: fixed; 
  width: 100px;
}     

</style> <script type="text/tiscript">

function self.ready() { var records = new Array(200); for(var i = 0; i < records.length; ++i) records[i] = { col1:i, col2:i, col3:i, col4:i, col5:i, col6:i, col7:i, col8:i };
$(table).value = records;
} </script> </head> <body> <table> <thead> <tr><th(col1) fixed>列1</th><th(col2) fixed>列2</th><th(col3)>列3</th><th(col4)>列4</th><th(col5)>列5</th><th(col6)>列6</th><th(col7)>列7</th><th(col8)>列8</th></tr> </thead> <tbody> <tr><td(col1) fixed></td><td(col2) fixed></td><td(col3)></td><td(col4)></td><td(col5)></td><td(col6)></td><td(col7)></td><td(col8)></td></tr> </tbody> </table> </body> </html>

and here is result:

How can I make the scorllbar of vgrid move to the topmost, and the first two columns can render correctly?

gxlmyacc commented 8 years ago

I'm sorry, I found that it has problem to achieve a fixed columns, please ignore this problem