Commit f0ce1cb2 authored by Yuriy Syrovetskiy's avatar Yuriy Syrovetskiy

Add QDate

parent 4534239e
......@@ -60,6 +60,7 @@ executable qtah-generator
, Graphics.UI.Qtah.Generator.Interface.Core.QChar
, Graphics.UI.Qtah.Generator.Interface.Core.QChildEvent
, Graphics.UI.Qtah.Generator.Interface.Core.QCoreApplication
, Graphics.UI.Qtah.Generator.Interface.Core.QDate
, Graphics.UI.Qtah.Generator.Interface.Core.QDir
, Graphics.UI.Qtah.Generator.Interface.Core.QEvent
, Graphics.UI.Qtah.Generator.Interface.Core.QItemSelection
......
......@@ -24,6 +24,7 @@ import qualified Graphics.UI.Qtah.Generator.Interface.Core.QByteArray as QByteAr
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QChar as QChar
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QChildEvent as QChildEvent
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QCoreApplication as QCoreApplication
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QDate as QDate
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QDir as QDir
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QEvent as QEvent
import qualified Graphics.UI.Qtah.Generator.Interface.Core.QItemSelection as QItemSelection
......@@ -65,6 +66,7 @@ modules =
, QChar.aModule
, QChildEvent.aModule
, QCoreApplication.aModule
, QDate.aModule
, QDir.aModule
, QEvent.aModule
, QItemSelection.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.Core.QDate (
aModule,
c_QDate,
) where
import Data.Bits ((.|.))
import Foreign.Hoppy.Generator.Spec (
Export (ExportBitspace, ExportEnum, ExportClass),
Operator (OpArray),
addReqIncludes,
classSetConversionToGc,
classSetEntityPrefix,
ident,
ident1,
includeStd,
makeClass,
mkConstMethod,
mkConstMethod',
mkCtor,
mkMethod,
mkProp,
mkStaticMethod,
)
import Foreign.Hoppy.Generator.Spec.ClassFeature (
ClassFeature (Assignable, Copyable, Equatable),
classAddFeatures,
)
import Foreign.Hoppy.Generator.Types (bitspaceT, boolT, intT, objT, refT, voidT)
import Foreign.Hoppy.Generator.Version (collect, just, test)
import Graphics.UI.Qtah.Generator.Flags (qtVersion)
import Graphics.UI.Qtah.Generator.Interface.Core.QChar (c_QChar)
import Graphics.UI.Qtah.Generator.Interface.Core.QString (c_QString)
import Graphics.UI.Qtah.Generator.Module (AModule (AQtModule), makeQtModule)
import Graphics.UI.Qtah.Generator.Types
{-# ANN module "HLint: ignore Use camelCase" #-}
aModule =
AQtModule $
makeQtModule ["Core", "QDate"]
[ QtExport $ ExportClass c_QDate
]
c_QDate =
addReqIncludes [includeStd "QDate"] $
classSetConversionToGc $
classAddFeatures [Assignable, Copyable, Equatable] $
classSetEntityPrefix "" $
makeClass (ident "QDate") Nothing [] $
collect
[ just $ mkCtor "new" []
, just $ mkCtor "newWithYearMonthDay" [intT, intT, intT]
]
......@@ -36,6 +36,7 @@ library
, Graphics.UI.Qtah.Core.QChar
, Graphics.UI.Qtah.Core.QChildEvent
, Graphics.UI.Qtah.Core.QCoreApplication
, Graphics.UI.Qtah.Core.QDate
, Graphics.UI.Qtah.Core.QDir
, Graphics.UI.Qtah.Core.QEvent
, Graphics.UI.Qtah.Core.QItemSelection
......@@ -201,6 +202,7 @@ library
, Graphics.UI.Qtah.Generated.Core.QChar
, Graphics.UI.Qtah.Generated.Core.QChildEvent
, Graphics.UI.Qtah.Generated.Core.QCoreApplication
, Graphics.UI.Qtah.Generated.Core.QDate
, Graphics.UI.Qtah.Generated.Core.QDir
, Graphics.UI.Qtah.Generated.Core.QEvent
, Graphics.UI.Qtah.Generated.Core.QItemSelection
......
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