Commit 0af5a04d authored by Yuriy Syrovetskiy's avatar Yuriy Syrovetskiy

Add QAbstractItemDelegate class

parent 7d11cd0f
......@@ -136,6 +136,7 @@ executable qtah-generator
, Graphics.UI.Qtah.Generator.Interface.Widgets
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractButton
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractGraphicsShapeItem
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemDelegate
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemView
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractScrollArea
, Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractSlider
......
......@@ -19,6 +19,7 @@ module Graphics.UI.Qtah.Generator.Interface.Widgets (modules) where
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractButton as QAbstractButton
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractGraphicsShapeItem as QAbstractGraphicsShapeItem
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemDelegate as QAbstractItemDelegate
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemView as QAbstractItemView
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractScrollArea as QAbstractScrollArea
import qualified Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractSlider as QAbstractSlider
......@@ -89,6 +90,7 @@ modules :: [AModule]
modules =
[ QAbstractButton.aModule
, QAbstractGraphicsShapeItem.aModule
, QAbstractItemDelegate.aModule
, QAbstractItemView.aModule
, QAbstractScrollArea.aModule
, QAbstractSlider.aModule
......
-- This file is part of Qtah.
--
-- Copyright 2018 The Qtah Authors.
--
-- This program is free software: you can redistribute it and/or modify
-- it under the terms of the GNU Lesser General Public License as published by
-- the Free Software Foundation, either version 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU Lesser General Public License for more details.
--
-- You should have received a copy of the GNU Lesser General Public License
-- along with this program. If not, see <http://www.gnu.org/licenses/>.
module Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemDelegate (
aModule,
c_QAbstractItemDelegate,
) where
import Foreign.Hoppy.Generator.Spec (
Export (ExportBitspace, ExportEnum, ExportClass),
addReqIncludes,
classSetEntityPrefix,
ident,
ident1,
includeStd,
makeClass,
mkBoolHasProp,
mkConstMethod,
mkMethod,
mkMethod',
mkProp,
)
import Foreign.Hoppy.Generator.Types (
bitspaceT,
boolT,
enumT,
intT,
objT,
ptrT,
voidT,
)
import Graphics.UI.Qtah.Generator.Interface.Core.QAbstractItemModel (c_QAbstractItemModel)
import Graphics.UI.Qtah.Generator.Interface.Core.QItemSelectionModel (c_QItemSelectionModel)
import Graphics.UI.Qtah.Generator.Interface.Core.QModelIndex (c_QModelIndex)
import Graphics.UI.Qtah.Generator.Interface.Core.QObject (c_QObject)
import Graphics.UI.Qtah.Generator.Interface.Core.QPoint (c_QPoint)
import Graphics.UI.Qtah.Generator.Interface.Core.QRect (c_QRect)
import Graphics.UI.Qtah.Generator.Interface.Core.QSize (c_QSize)
import Graphics.UI.Qtah.Generator.Interface.Core.QString (c_QString)
import Graphics.UI.Qtah.Generator.Interface.Core.Types (
e_DropAction,
e_TextElideMode,
)
import Graphics.UI.Qtah.Generator.Interface.Internal.Listener (
c_Listener,
c_ListenerQModelIndex,
c_ListenerQSize,
)
import Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractScrollArea (c_QAbstractScrollArea)
import Graphics.UI.Qtah.Generator.Interface.Widgets.QWidget (c_QWidget)
import Graphics.UI.Qtah.Generator.Module (AModule (AQtModule), makeQtModule)
import Graphics.UI.Qtah.Generator.Types
{-# ANN module "HLint: ignore Use camelCase" #-}
aModule =
AQtModule $
makeQtModule ["Widgets", "QAbstractItemDelegate"] $
QtExport (ExportClass c_QAbstractItemDelegate) :
map QtExportSignal signals
c_QAbstractItemDelegate =
addReqIncludes [includeStd "QAbstractItemDelegate"] $
classSetEntityPrefix "" $
makeClass (ident "QAbstractItemDelegate") Nothing [c_QObject] $
[
]
signals =
[
]
......@@ -30,6 +30,7 @@ import Foreign.Hoppy.Generator.Spec (
makeClass,
mkBoolHasProp,
mkConstMethod,
mkConstMethod',
mkMethod,
mkMethod',
mkProp,
......@@ -59,6 +60,7 @@ import Graphics.UI.Qtah.Generator.Interface.Internal.Listener (
c_ListenerQModelIndex,
c_ListenerQSize,
)
import Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractItemDelegate (c_QAbstractItemDelegate)
import Graphics.UI.Qtah.Generator.Interface.Widgets.QAbstractScrollArea (c_QAbstractScrollArea)
import Graphics.UI.Qtah.Generator.Interface.Widgets.QWidget (c_QWidget)
import Graphics.UI.Qtah.Generator.Module (AModule (AQtModule), makeQtModule)
......@@ -100,11 +102,14 @@ c_QAbstractItemView =
, mkProp "iconSize" $ objT c_QSize
, mkConstMethod "indexAt" [objT c_QPoint] $ objT c_QModelIndex
, mkConstMethod "indexWidget" [objT c_QModelIndex] $ ptrT $ objT c_QWidget
-- TODO mkConstMethod' "itemDelegate" "itemDelegate" [] $ ptrT $ objT c_QAbstractItemDelegate
-- TODO mkConstMethod' "itemDelegate" "itemDelegateAt" [objT c_QModelIndex] $
-- ptrT $ objT c_QAbstractItemDelegate
-- TODO mkConstMethod "itemDelegateForColumn" [intT] $ ptrT $ objT c_QAbstractItemDelegate
-- TODO mkConstMethod "itemDelegateForRow" [intT] $ ptrT $ objT c_QAbstractItemDelegate
, mkConstMethod' "itemDelegate" "itemDelegate" [] $
ptrT $ objT c_QAbstractItemDelegate
, mkConstMethod' "itemDelegate" "itemDelegateAt" [objT c_QModelIndex] $
ptrT $ objT c_QAbstractItemDelegate
, mkConstMethod "itemDelegateForColumn" [intT] $
ptrT $ objT c_QAbstractItemDelegate
, mkConstMethod "itemDelegateForRow" [intT] $
ptrT $ objT c_QAbstractItemDelegate
, mkMethod "keyboardSearch" [objT c_QString] voidT
, mkProp "model" $ ptrT $ objT c_QAbstractItemModel
, mkMethod "openPersistentEditor" [objT c_QModelIndex] voidT
......
......@@ -125,6 +125,7 @@ library
, Graphics.UI.Qtah.Std
, Graphics.UI.Qtah.Widgets.QAbstractButton
, Graphics.UI.Qtah.Widgets.QAbstractGraphicsShapeItem
, Graphics.UI.Qtah.Widgets.QAbstractItemDelegate
, Graphics.UI.Qtah.Widgets.QAbstractItemView
, Graphics.UI.Qtah.Widgets.QAbstractScrollArea
, Graphics.UI.Qtah.Widgets.QAbstractSlider
......@@ -280,6 +281,7 @@ library
, Graphics.UI.Qtah.Generated.Internal.SceneEventListener
, Graphics.UI.Qtah.Generated.Widgets.QAbstractButton
, Graphics.UI.Qtah.Generated.Widgets.QAbstractGraphicsShapeItem
, Graphics.UI.Qtah.Generated.Widgets.QAbstractItemDelegate
, Graphics.UI.Qtah.Generated.Widgets.QAbstractItemView
, Graphics.UI.Qtah.Generated.Widgets.QAbstractScrollArea
, Graphics.UI.Qtah.Generated.Widgets.QAbstractSlider
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment