001 /* 002 * Licensed to the Apache Software Foundation (ASF) under one 003 * or more contributor license agreements. See the NOTICE file 004 * distributed with this work for additional information 005 * regarding copyright ownership. The ASF licenses this file 006 * to you under the Apache License, Version 2.0 (the 007 * "License"); you may not use this file except in compliance 008 * with the License. You may obtain a copy of the License at 009 * 010 * http://www.apache.org/licenses/LICENSE-2.0 011 * 012 * Unless required by applicable law or agreed to in writing, 013 * software distributed under the License is distributed on an 014 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 015 * KIND, either express or implied. See the License for the 016 * specific language governing permissions and limitations 017 * under the License. 018 */ 019 020 package org.apache.myfaces.tobago.taglib.component; 021 022 import org.apache.myfaces.tobago.apt.annotation.BodyContent; 023 import org.apache.myfaces.tobago.apt.annotation.Tag; 024 import org.apache.myfaces.tobago.apt.annotation.UIComponentTag; 025 import org.apache.myfaces.tobago.taglib.decl.HasBinding; 026 import org.apache.myfaces.tobago.taglib.decl.HasBorder; 027 import org.apache.myfaces.tobago.taglib.decl.HasCellspacing; 028 import org.apache.myfaces.tobago.taglib.decl.HasColumnLayout; 029 import org.apache.myfaces.tobago.taglib.decl.HasId; 030 import org.apache.myfaces.tobago.taglib.decl.HasMargin; 031 import org.apache.myfaces.tobago.taglib.decl.HasMargins; 032 import org.apache.myfaces.tobago.taglib.decl.HasRowLayout; 033 034 /* 035 * Date: 14.03.2006 036 * Time: 16:58:13 037 */ 038 039 /** 040 * Renders a GridLayout. 041 * <pre> 042 * columns/rows ::= LAYOUT 043 * LAYOUT ::= TOKEN [";" TOKEN]+ 044 * TOKEN ::= FIXED | PIXEL | PROPORTIONAL 045 * FIXED ::= "fixed" 046 * PIXEL ::= NUMBER "px" 047 * PROPORTIONAL ::= [NUMBER] "*" 048 * </pre> 049 * <p/> 050 * <table border="1"> 051 * <tr> 052 * <th>Parent</th> 053 * <th>Child</th> 054 * <th>Okay?</th> 055 * <th>Remarks</th> 056 * </tr> 057 * <tr> 058 * <td>FIXED</td> 059 * <td>any combination of FIXED or PIXEL but no PROPORTIONAL</td> 060 * <td>okay</td> 061 * <td>-</td> 062 * </tr> 063 * <tr> 064 * <td>FIXED</td> 065 * <td>any combination with at least one PROPORTIONAL</td> 066 * <td>wrong</td> 067 * <td>LayoutManager cannot compute the fixed value.</td> 068 * </tr> 069 * <tr> 070 * <td>PIXEL</td> 071 * <td>any combination of FIXED or PIXEL but no PROPORTIONAL</td> 072 * <td>potentially wrong</td> 073 * <td>The values depend on each other, the programmer has to keep consistency manually.</td> 074 * </tr> 075 * <tr> 076 * <td>PIXEL</td> 077 * <td>any combination with at least one PROPORTIONAL</td> 078 * <td>okay</td> 079 * <td>-</td> 080 * </tr> 081 * <tr> 082 * <td>PROPORTIONAL</td> 083 * <td>any combination of FIXED or PIXEL but no PROPORTIONAL</td> 084 * <td>potentially wrong</td> 085 * <td>No automatical matching:<ul><li>too little space: scrollbar</li> 086 * <li>too much space: elements will be spreaded.</li></ul></td> 087 * </tr> 088 * <tr> 089 * <td>PROPORTIONAL</td> 090 * <td>any combination with at least one PROPORTIONAL</td> 091 * <td>okay</td> 092 * <td>-</td> 093 * </tr> 094 * </table> 095 */ 096 @Tag(name = "gridLayout", bodyContent = BodyContent.EMPTY) 097 @UIComponentTag( 098 uiComponent = "org.apache.myfaces.tobago.component.UIGridLayout", 099 rendererType = "GridLayout") 100 public interface GridLayoutTagDeclaration extends TobagoTagDeclaration, HasId, HasBorder, HasCellspacing, HasMargin, 101 HasMargins, HasColumnLayout, HasRowLayout, HasBinding { 102 }