¡@

Home 

2014/10/16 ¤W¤È 08:11:06

android Programming Glossary: cellwidthfactor

Creating a table/grid with a frozen column and frozen headers

http://stackoverflow.com/questions/7586753/creating-a-table-grid-with-a-frozen-column-and-frozen-headers

TableLayout contentTable Typeface font float fontSize int cellWidthFactor ObservableHorizontalScrollView headerScrollView ObservableHorizontalScrollView.. getBaseContext .getResources .getDisplayMetrics .density cellWidthFactor int Math.ceil fontSize scale fontSize 10 0.9 0.7 Button backButton.. i int replacementWidth widths i 1 int Math.ceil widths i cellWidthFactor 2 widths i 3 int Math.ceil widths i cellWidthFactor 1.7 ..

Creating a table/grid with a frozen column and frozen headers

http://stackoverflow.com/questions/7586753/creating-a-table-grid-with-a-frozen-column-and-frozen-headers

contentHeaderTable private TableLayout frozenTable private TableLayout contentTable Typeface font float fontSize int cellWidthFactor ObservableHorizontalScrollView headerScrollView ObservableHorizontalScrollView contentScrollView public void onCreate Bundle.. but that code is removed for clarity final float scale getBaseContext .getResources .getDisplayMetrics .density cellWidthFactor int Math.ceil fontSize scale fontSize 10 0.9 0.7 Button backButton Button findViewById R.id.backButton frozenTable TableLayout.. i row.getChildCount i TextView cell TextView row.getChildAt i int replacementWidth widths i 1 int Math.ceil widths i cellWidthFactor 2 widths i 3 int Math.ceil widths i cellWidthFactor 1.7 widths i 5 int Math.ceil widths i cellWidthFactor 1.2 widths..