Layouts To understand various layouts extjs provides, and overview of some commonly used layouts.

Slides:



Advertisements
Similar presentations
Chapter 3 – Web Design Tables & Page Layout
Advertisements

Copyright © 2004 ProsoftTraining, All Rights Reserved. Lesson 6: HTML Tables.
Working with Tables for Page Design – Lesson 41 Working with Tables for Page Design Lesson 4.
Intermediate Level Course. Text Format The text styles, bold, italics, underlining, superscript and subscript, can be easily added to selected text. Text.
Web-based Application Development Lecture 9 February 7, 2006 Anita Raja.
XHTML1 Tables and Lists. XHTML2 Objectives In this chapter, you will: Create basic tables Structure tables Format tables Create lists.
1 Computing for Todays Lecture 20 Yumei Huo Fall 2006.
Tables And Lists. Slide 2 Lecture Overview Learn about the basics of tables Create simple 2-dimensional tables Format tables Create tables with complex.
Notes Ch. 12—Creating Tables Web Page Design. Why Use Tables? Tables are used to create a variety of items such as calendars, charts, and spreadsheets.
INTRODUCTION TO WEB DEVELOPMENT AND HTML Lecture 06: Tables - Spring 2011.
HTML Tables and Forms Creating Web Pages with HTML CIS 133 Web Programming Concepts 1.
HTML Essentials Tables and Table Tags. Overview Use of Tables goes beyond tabulating data Frequently used to format Web pages / control layout Especially.
XHTML1 Tables N100 Creating a Simple Web Page. XHTML2 Creating Basic Tables Tables are collections of rows and columns that you use to organize and display.
1 The Structure of a Web Table beginning of the table structure first row of three in the table end of the table structure table cells You do not need.
CHAPTER 11 Tables. How Are Tables Used Data Display  Very tidy and very useful Better Text Alignment  Putting text in tables allows you to format indents.
XP New Perspectives on Microsoft Office PowerPoint 2003 Tutorial 2 1 Microsoft Office PowerPoint 2003 Tutorial 2 – Applying and Modifying Text and Graphic.
Tutorial 6 Creating Tables and CSS Layouts. Objectives Session 6.1 – Create a data table to display and organize data – Modify table properties and layout.
Tutorial 4: Using CSS for Page Layout. 2 Objectives Session 4.1 Explore CSS layout Compare types of floating layouts Examine code for CSS layouts View.
Tutorial 5 Working with Web Tables. XP Objectives Explore the structure of a Web table Create headings and cells in a table Create cells that span multiple.
Tables Learning Web Design: Chapter 8. Overview of Tables Uses for tables How to create a table Using CSS to style a table Nested tables Advanced table.
Website Development with Dreamweaver
CHAPTER 10 Formatting Tables and Forms. Using Tables the Right Way  HTML and XHTML have a LOT of tags dedicated to building a table  If you have only.
10/4/2015Tables1 Spring, 2008 Modified by Linda Kenney 4/2/08.
Java Software Solutions Lewis and Loftus Chapter 10 1 Copyright 1997 by John Lewis and William Loftus. All rights reserved. Graphical User Interfaces --
McGraw-Hill Career Education© 2008 by the McGraw-Hill Companies, Inc. All Rights Reserved. 2-1 Office PowerPoint 2007 Lab 2 Modifying and Refining a Presentation.
Domain 3 Understanding the Adobe Dreamweaver CS5 Interface.
XP New Perspectives on Microsoft Word 2002 Tutorial 31 Microsoft Word 2002 Tutorial 3 – Creating a Multiple-Page Report.
Designing a Web Page with Tables. A text table: contains only text, evenly spaced on the Web page in rows and columns uses only standard word processing.
Tutorial 5 Working with Tables and Columns
Department of Information Technology Chapter 9 – Creating Tables Lecturer: Ms Melinda Chung.
Tutorial 5 Working with Tables and Columns
Object Oriented Software Development 9. Creating Graphical User Interfaces.
CSCE 102 – Chapter 6 (Web Design and Layout) CSCE General Applications Programming Benito Mendoza Benito Mendoza 1 By Benito Mendoza.
Html Tables Basic Table Markup. How Tables are Used For Data Display Tables were originally designed to display and organize tabular data (charts, statistics,
Chapter 5 Quick Links Slide 2 Performance Objectives Understanding Framesets and Frames Creating Framesets and Frames Selecting Framesets and Frames Using.
HTML: Tables & Frames Internet Technology.
Copyright 2006 South-Western/Thomson Learning Chapter 12 Tables.
4 Chapter Four Introduction to HTML. 4 Chapter Objectives Learn basic HTML commands Discover how to display graphic image objects in Web pages Create.
© 2008 The McGraw-Hill Companies, Inc. All rights reserved. WORD 2007 M I C R O S O F T ® THE PROFESSIONAL APPROACH S E R I E S Lesson 15 Advanced Tables.
WaveMaker Visual AJAX Studio 4.0 Training Basics: Building Your First Application Designer Basics.
Lesson 7. Tables Table Tags and Attributes Tables HTML tables are used in two main ways: 1.To organize tabular data in a familiar spreadsheet-like way.
Copyright © 2009 Pearson Education, Inc. Publishing as Prentice Hall. 1 Skills for Success with Microsoft ® Office 2007 PowerPoint Lecture to Accompany.
Copyright (c) 2004 Prentice-Hall. All rights reserved. 1 Committed to Shaping the Next Generation of IT Experts. Project 5: Working with Tables Kelly L.
Microsoft Access 2000 Presentation 3 Creating Databases Part II (Creating Forms)
1 Lesson 13 Organizing and Enhancing Worksheets Computer Literacy BASICS: A Comprehensive Guide to IC 3, 3 rd Edition Morrison / Wells.
Lecture 6 More Advanced HTML Boriana Koleva Room: C54
Key Applications Module Lesson 14 — Working with Tables Computer Literacy BASICS.
20-753: Fundamentals of Web Programming 1 Lecture 6: Advanced HTML Fundamentals of Web Programming Lecture 6: Advanced HTML.
Positioning Objects with CSS and Tables
©SoftMoore ConsultingSlide 1 Introduction to HTML: Block-Level Elements.
Copyright © 2012 Certification Partners, LLC -- All Rights Reserved Lesson 5: HTML Tables.
Tutorial 5 Working with Web Tables. New Perspectives on HTML, XHTML, and XML, Comprehensive, 3rd Edition 2 Objectives Learn and Apply the structure of.
Lesson 13 Tables. Overview Create a table. Key and edit text in tables. Select cells, rows, and columns. Edit table structures. Format tables and cell.
XP New Perspectives on Microsoft Office FrontPage 2003 Tutorial 5 1 Microsoft Office FrontPage 2003 Tutorial 5 – Creating Tables and Frames.
Laying out Elements with CSS
Microsoft Office PowerPoint 2003
CSS Layouts: Grouping Elements
Microsoft Office 2007-Illustrated
Working with Tables: Module A: Table Basics
Positioning Objects with CSS and Tables
Building a User Interface with Forms
Chap 7. Building Java Graphical User Interfaces
The Internet 10/25/11 XHTML Tables
Objectives Create a reset style sheet Explore page layout designs
Tutorial 3 – Creating a Multiple-Page Report
DREAMWEAVER MX 2004 Chapter 3 Working with Tables
Lesson 5: HTML Tables.
Positioning Objects with CSS and Tables
Presentation transcript:

Layouts To understand various layouts extjs provides, and overview of some commonly used layouts

Component Model Component provides a unified model for component creation, rendering, event handling, state management and destruction, and every component in Ext that requires these features now extends Component. It is one of the most fundamental classes in the overall architecture.

Component Life Cycle: Initialization 1. The config object is applied 2. The base Component events are created 3. The component is registered in ComponentMgr 4. The initComponent method is called 5. Plugins are loaded (if applicable) 6. State is initialized (if applicable) 7. The component is rendered (if applicable)

Component Life Cycle: Rendering 1. The beforerender event is fired 2. The container is set 3. The onRender method is called 4. The Component is "unhidden" 5. Custom class and/or style applied 6. The render event is fired 7. The afterRender method is called 8. The Component is hidden and/or disabled (if applicable) 9. Any state-specific events are initialized (if applicable) 10. The afterrender event is fired

Component Life Cycle: Destruction 1. The beforedestroy event is fired 2. The beforeDestroy method is called 3. Element and its listeners are removed 4. The onDestroy method is called 5. Component is unregistered from ComponentMgr 6. The destroy event is fired 7. Event listeners on the Component are removed

Container Model Container Container is the most basic foundation for any component that will contain other components. It provides the layout and rendering logic needed for handling sizing and nesting of other components, and also provides the basic mechanism for consistently adding components to the container.. Panel Panel also provides the basic building blocks needed in an application UI. It has bottom and top bars for adding toolbars and menus, a header, footer and body. Panels can be easily dropped into any Container or layout. * GridPanel * TabPanel * TreePanel * FormPanel Window Window is a specialized Panel that also can be floated, minimized/maximized, restored, dragged, etc. Viewport The Viewport is a utility container class that automatically renders to the document body and sizes itself to the dimensions of the browser viewport.

Layouts note*: extjs 3-0 has added a BoxLayout subclass of ContainerLayout

Adding Layout layout: 'accordion', // The layout style to use in this panel layoutConfig: { animate: true // Layout-specific config values go here }

AbsoluteLayout This is a very simple layout that allows you to position contained items precisely via X/Y coordinates relative to the container. layout:'absolute', items: [{ x: 0, y: 5, xtype:'label', text: 'Send To:' },{ x: 0, y: 35, xtype:'label', text: 'Subject:' }]

AccordionLayout The AccordionLayout contains a set of vertically-stacked panels that can be expanded and collapsed to display content. Only one panel can be open at a time layout:'accordion', layoutConfig: { // layout-specific configs go here titleCollapse: false, fill: true, hideCollapseTool: true, collapseFirst: false, animate: true, activeOnTop: true }, items: [{ title: 'Panel 1', html: ' Panel content! ' },{ title: 'Panel 2', html: ' Panel content! ' },{ title: 'Panel 3', html: ' Panel content! ' }]

AnchorLayout This layout is for anchoring elements relative to the sides of the container. The elements can be anchored by percentage or by offsets from the edges, and it also supports a virtual layout canvas that can have different dimensions than the physical container. layout:'anchor', anchorSize: {width:800, height:600}, items:[{ title:'Item 1', html:'Content 1', anchor:'right 20%' // valid values right, bottom },{ title:'Item 2', html:'Content 2', anchor:'50% 30%' },{ title:'Item 3', html:'Content 3', anchor:' %' }]

BorderLayout This layout regions with built-in support for nesting, sliding panels open and closed and splitters separating regions. This is the most common layout style for the primary UI in typical business applications layout: 'border', items: [{ title: 'South Region is resizable', region: 'south', // position for region height: 100, split: true, // enable resizing minSize: 75, // defaults to 50 maxSize: 150, margins: ' ' },{ title: 'West Region is collapsible', region:'west', width: 200, collapsible: true, // make collapsible cmargins: ' ', // adjust top margin when collapsed },{ title: 'Center Region', region: 'center' // center region is required, no width/height specified }]

BorderLayout:Region cmargins An object containing margins to apply to the region when in the collapsed state respectively. collapseMode – undefined (default) – 'mini' collapsible true to allow the user to collapse this region margins An object containing margins to apply to the region when in the expanded state minHeight minWidth split

CardLayout CardLayout is a specific layout used in cases where a container holds multiple elements, but only a single item can be visible at any given time. layout:'card', layoutConfig: { deferredRender : false, layoutOnCardChange : true }, activeItem: 0, // make sure the active item is set on the container config! // the panels (or "cards") within the layout items: [{ id: 'card-0', html: ' Welcome to the Wizard! Step 1 of 3 ' },{ id: 'card-1', html: ' Step 2 of 3 ' },{ id: 'card-2', html: ' Congratulations! Step 3 of 3 - Complete ' }]

ColumnLayout This is the layout style of choice for creating structural layouts in a multi- column format where the width of each column can be specified as a percentage or pixel width, but the height is allowed to vary based on content. layout:'column', items: [{ title: 'Column 1', columnWidth:.25 },{ title: 'Column 2', columnWidth:.6 },{ title: 'Column 3', columnWidth:.15 }]

FitLayout This is a simple layout style that fits a single contained item to the exact dimensions of the container. This is usually the best default layout to use within containers when no other specific layout style is called for. layout:'fit', items: { title: 'Inner Panel', html: ' This is the inner panel content ', border: false }

FormLayout The FormLayout is a utility layout specifically designed for creating data entry forms. FormPanels must use layout:'form', so forms needing additional layout styles should use nested Panels to provide them. A Container using the FormLayout layout manager (e.g. Ext.form.FormPanel or specifying layout:'form') can also accept the following layout-specific config properties: – hideLabels – labelAlign – labelPad – labelSeparator – labelWidth Any Component (including Fields) managed by FormLayout accepts the following as a config option: – anchor

layout: 'form', hideLabels: false, labelAlign: 'left', // or 'right' or 'top' labelSeparator: '>>', labelWidth: 65, // defaults to 100 labelPad: 8, items: [{ fieldLabel: 'First Name', name: 'first', labelSeparator: ':' // override labelSeparator layout config },{ fieldLabel: 'Last Name', name: 'last' },{ fieldLabel: ' ', name: ' ' }, { xtype: 'textarea', hideLabel: true,// override hideLabels layout config name: 'msg', anchor: '100% -53' } ]

TableLayout This layout style generates standard HTML table markup with support for column and row spanning. // // | A | B | // | | | // | | C | D | // layout:'table', layoutConfig: { columns: 3 }, items: [{ html: ' Cell A content ', rowspan: 2 },{ html: ' Cell B content ', colspan: 2 },{ html: ' Cell C content ' },{ html: ' Cell D content ' }]

HBoxLayout A layout that arranges items horizontally across a Container. l layout:'hbox', layoutConfig: { padding:'5', align:'stretch', //Controls how the child items of the container are aligned flex: 1, pack: 'start'//Controls how the child items of the container are packed together. }, items:[{ xtype:'button', text: 'Button 1' },{ xtype:'button', text: 'Button 2' },{ xtype:'button', text: 'Button 3' },{ xtype:'button', text: 'Button 4' }]

VBoxLayout A layout that arranges items vertically down a Container layout:'vbox', layoutConfig: { padding:'5', align:'left',//Controls how the child items of the container are aligned. flex: 1 // pack: 'start'//Controls how the child items of the container are packed together. }, items:[{ xtype:'button', text: 'Button 1' },{ xtype:'button', text: 'Button 2' },{ xtype:'button', text: 'Button 3' },{ xtype:'button', text: 'Button 4 }]