    001    // Copyright 2008 The Apache Software Foundation
    002    //
    003    // Licensed under the Apache License, Version 2.0 (the "License");
    004    // you may not use this file except in compliance with the License.
    005    // You may obtain a copy of the License at
    006    //
    007    //     http://www.apache.org/licenses/LICENSE-2.0
    008    //
    009    // Unless required by applicable law or agreed to in writing, software
    010    // distributed under the License is distributed on an "AS IS" BASIS,
    011    // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    012    // See the License for the specific language governing permissions and
    013    // limitations under the License.
    014
    015    package org.apache.tapestry5.grid;
    016
    017    public class GridConstants
    018    {
    019        /**
    020         * CSS class for the first column or the first row. May be applied to a &lt;th&gt; (in the &lt;thead&gt;) or a
    021         * &lt;tr&gt; (in the &lt;tbody&gt;).
    022         */
    023        public static final String FIRST_CLASS = "t-first";
    024
    025        /**
    026         * CSS class for the last column or the last row. May be applied to a &lt;th&gt; (in the &lt;thead&gt;) or a
    027         * &lt;tr&gt; (in the &lt;tbody&gt;).
    028         */
    029        public static final String LAST_CLASS = "t-last";
    030
    031        /**
    032         * Marks the column that is currently sorted for sort ascending.  May be applied to a &lt;th&gt; (in the
    033         * &lt;thead&gt; or a &lt;td&gt; in the &lt;tbody&gt;).
    034         */
    035        public static final String SORT_ASCENDING_CLASS = "t-sort-column-ascending";
    036
    037        /**
    038         * Marks the column that is currently sorted for sort descending.  May be applied to a &lt;th&gt; (in the
    039         * &lt;thead&gt; or a &lt;td&gt; in the &lt;tbody&gt;).
    040         */
    041
    042        public static final String SORT_DESCENDING_CLASS = "t-sort-column-descending";
    043
    044        /**
    045         * Number of rows to diplay within each {@link org.apache.tapestry5.corelib.components.Grid} page.
    046         */
    047        public static final int ROWS_PER_PAGE = 25;
    048
    049        /**
    050         * CSS class for the &lt;table&gt; element.
    051         */
    052        public static final String TABLE_CLASS = "t-data-grid";
    053
    054        /**
    055         * Default pager position
    056         */
    057        public static final String PAGER_POSITION = "top";
    058
    059        /**
    060         * Block name to display in place of an empty {@link org.apache.tapestry5.corelib.components.Grid}
    061         */
    062        public static final String EMPTY_BLOCK = "block:empty";
    063
    064        /**
    065         * Default number of page to display before and after the current page in the
    066         * {@link org.apache.tapestry5.corelib.components.GridPager}
    067         */
    068        public static final int PAGER_PAGE_RANGE = 5;
    069
    070        /**
    071         * Default {@link org.apache.tapestry5.Asset} for ascending columns sort
    072         */
    073        public static final String COLUMNS_ASCENDING = "sort-asc.png";
    074
    075        /**
    076         * Default {@link org.apache.tapestry5.Asset} for ascending columns sort
    077         */
    078        public static final String COLUMNS_DESCENDING = "sort-desc.png";
    079
    080        /**
    081         * Default {@link org.apache.tapestry5.Asset} for sortable columns
    082         */
    083        public static final String COLUMNS_SORTABLE = "sortable.png";
    084    }