18e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project/* 28e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 38e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * (C) 2000 Antti Koivisto (koivisto@kde.org) 48e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * (C) 2000 Dirk Mueller (mueller@kde.org) 58e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Copyright (C) 2003, 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 68e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 78e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * 88e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * This library is free software; you can redistribute it and/or 98e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * modify it under the terms of the GNU Library General Public 108e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * License as published by the Free Software Foundation; either 118e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * version 2 of the License, or (at your option) any later version. 128e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * 138e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * This library is distributed in the hope that it will be useful, 148e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * but WITHOUT ANY WARRANTY; without even the implied warranty of 158e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 168e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Library General Public License for more details. 178e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * 188e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * You should have received a copy of the GNU Library General Public License 198e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * along with this library; see the file COPYING.LIB. If not, write to 208e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 218e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * Boston, MA 02110-1301, USA. 228e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project * 238e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project */ 248e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 258e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#ifndef StyleBoxData_h 268e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#define StyleBoxData_h 278e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 288e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#include "Length.h" 29dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block#include "RenderStyleConstants.h" 308e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#include <wtf/RefCounted.h> 318e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#include <wtf/PassRefPtr.h> 328e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 338e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Projectnamespace WebCore { 348e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 358e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Projectclass StyleBoxData : public RefCounted<StyleBoxData> { 368e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Projectpublic: 378e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project static PassRefPtr<StyleBoxData> create() { return adoptRef(new StyleBoxData); } 388e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project PassRefPtr<StyleBoxData> copy() const { return adoptRef(new StyleBoxData(*this)); } 398e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 408e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project bool operator==(const StyleBoxData& o) const; 418e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project bool operator!=(const StyleBoxData& o) const 428e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project { 438e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project return !(*this == o); 448e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project } 458e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 46dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length width() const { return m_width; } 47dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length height() const { return m_height; } 48dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 49dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length minWidth() const { return m_minWidth; } 50dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length minHeight() const { return m_minHeight; } 51dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 52dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length maxWidth() const { return m_maxWidth; } 53dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length maxHeight() const { return m_maxHeight; } 54dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 55dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length verticalAlign() const { return m_verticalAlign; } 56dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 57dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block int zIndex() const { return m_zIndex; } 58dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block bool hasAutoZIndex() const { return m_hasAutoZIndex; } 598e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 60dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block EBoxSizing boxSizing() const { return static_cast<EBoxSizing>(m_boxSizing); } 61dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 628e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Projectprivate: 63dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block friend class RenderStyle; 64dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 658e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project StyleBoxData(); 668e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project StyleBoxData(const StyleBoxData&); 67dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 68dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_width; 69dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_height; 70dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 71dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_minWidth; 72dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_maxWidth; 73dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 74dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_minHeight; 75dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_maxHeight; 76dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 77dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block Length m_verticalAlign; 78dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block 79dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block int m_zIndex; 80dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block bool m_hasAutoZIndex : 1; 81dcc8cf2e65d1aa555cce12431a16547e66b469eeSteve Block unsigned m_boxSizing : 1; // EBoxSizing 828e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project}; 838e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 848e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project} // namespace WebCore 858e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project 868e35f3cfc7fba1d1c829dc557ebad6409cbe16a2The Android Open Source Project#endif // StyleBoxData_h 87