{- | Copyright : Will Thompson, Iñaki García Etxebarria and Jonas Platte License : LGPL-2.1 Maintainer : Iñaki García Etxebarria (garetxe@gmail.com) -} module GI.WebKit2WebExtension.Objects.DOMHTMLLabelElement ( -- * Exported types DOMHTMLLabelElement(..) , DOMHTMLLabelElementK , toDOMHTMLLabelElement , noDOMHTMLLabelElement , -- * Methods -- ** dOMHTMLLabelElementGetForm dOMHTMLLabelElementGetForm , -- ** dOMHTMLLabelElementGetHtmlFor dOMHTMLLabelElementGetHtmlFor , -- ** dOMHTMLLabelElementSetHtmlFor dOMHTMLLabelElementSetHtmlFor , -- * Properties -- ** Control DOMHTMLLabelElementControlPropertyInfo , getDOMHTMLLabelElementControl , -- ** Form DOMHTMLLabelElementFormPropertyInfo , getDOMHTMLLabelElementForm , -- ** HtmlFor DOMHTMLLabelElementHtmlForPropertyInfo , constructDOMHTMLLabelElementHtmlFor , getDOMHTMLLabelElementHtmlFor , setDOMHTMLLabelElementHtmlFor , ) where import Prelude () import Data.GI.Base.ShortPrelude import qualified Data.Text as T import qualified Data.ByteString.Char8 as B import qualified Data.Map as Map import GI.WebKit2WebExtension.Types import GI.WebKit2WebExtension.Callbacks import qualified GI.GObject as GObject newtype DOMHTMLLabelElement = DOMHTMLLabelElement (ForeignPtr DOMHTMLLabelElement) foreign import ccall "webkit_dom_html_label_element_get_type" c_webkit_dom_html_label_element_get_type :: IO GType type instance ParentTypes DOMHTMLLabelElement = DOMHTMLLabelElementParentTypes type DOMHTMLLabelElementParentTypes = '[DOMHTMLElement, DOMElement, DOMNode, DOMObject, GObject.Object, DOMEventTarget] instance GObject DOMHTMLLabelElement where gobjectIsInitiallyUnowned _ = False gobjectType _ = c_webkit_dom_html_label_element_get_type class GObject o => DOMHTMLLabelElementK o instance (GObject o, IsDescendantOf DOMHTMLLabelElement o) => DOMHTMLLabelElementK o toDOMHTMLLabelElement :: DOMHTMLLabelElementK o => o -> IO DOMHTMLLabelElement toDOMHTMLLabelElement = unsafeCastTo DOMHTMLLabelElement noDOMHTMLLabelElement :: Maybe DOMHTMLLabelElement noDOMHTMLLabelElement = Nothing -- VVV Prop "control" -- Type: TInterface "WebKit2WebExtension" "DOMHTMLElement" -- Flags: [PropertyReadable] getDOMHTMLLabelElementControl :: (MonadIO m, DOMHTMLLabelElementK o) => o -> m DOMHTMLElement getDOMHTMLLabelElementControl obj = liftIO $ getObjectPropertyObject obj "control" DOMHTMLElement data DOMHTMLLabelElementControlPropertyInfo instance AttrInfo DOMHTMLLabelElementControlPropertyInfo where type AttrAllowedOps DOMHTMLLabelElementControlPropertyInfo = '[ 'AttrGet] type AttrSetTypeConstraint DOMHTMLLabelElementControlPropertyInfo = (~) () type AttrBaseTypeConstraint DOMHTMLLabelElementControlPropertyInfo = DOMHTMLLabelElementK type AttrGetType DOMHTMLLabelElementControlPropertyInfo = DOMHTMLElement type AttrLabel DOMHTMLLabelElementControlPropertyInfo = "DOMHTMLLabelElement::control" attrGet _ = getDOMHTMLLabelElementControl attrSet _ = undefined attrConstruct _ = undefined -- VVV Prop "form" -- Type: TInterface "WebKit2WebExtension" "DOMHTMLFormElement" -- Flags: [PropertyReadable] getDOMHTMLLabelElementForm :: (MonadIO m, DOMHTMLLabelElementK o) => o -> m DOMHTMLFormElement getDOMHTMLLabelElementForm obj = liftIO $ getObjectPropertyObject obj "form" DOMHTMLFormElement data DOMHTMLLabelElementFormPropertyInfo instance AttrInfo DOMHTMLLabelElementFormPropertyInfo where type AttrAllowedOps DOMHTMLLabelElementFormPropertyInfo = '[ 'AttrGet] type AttrSetTypeConstraint DOMHTMLLabelElementFormPropertyInfo = (~) () type AttrBaseTypeConstraint DOMHTMLLabelElementFormPropertyInfo = DOMHTMLLabelElementK type AttrGetType DOMHTMLLabelElementFormPropertyInfo = DOMHTMLFormElement type AttrLabel DOMHTMLLabelElementFormPropertyInfo = "DOMHTMLLabelElement::form" attrGet _ = getDOMHTMLLabelElementForm attrSet _ = undefined attrConstruct _ = undefined -- VVV Prop "html-for" -- Type: TBasicType TUTF8 -- Flags: [PropertyReadable,PropertyWritable] getDOMHTMLLabelElementHtmlFor :: (MonadIO m, DOMHTMLLabelElementK o) => o -> m T.Text getDOMHTMLLabelElementHtmlFor obj = liftIO $ getObjectPropertyString obj "html-for" setDOMHTMLLabelElementHtmlFor :: (MonadIO m, DOMHTMLLabelElementK o) => o -> T.Text -> m () setDOMHTMLLabelElementHtmlFor obj val = liftIO $ setObjectPropertyString obj "html-for" val constructDOMHTMLLabelElementHtmlFor :: T.Text -> IO ([Char], GValue) constructDOMHTMLLabelElementHtmlFor val = constructObjectPropertyString "html-for" val data DOMHTMLLabelElementHtmlForPropertyInfo instance AttrInfo DOMHTMLLabelElementHtmlForPropertyInfo where type AttrAllowedOps DOMHTMLLabelElementHtmlForPropertyInfo = '[ 'AttrSet, 'AttrConstruct, 'AttrGet] type AttrSetTypeConstraint DOMHTMLLabelElementHtmlForPropertyInfo = (~) T.Text type AttrBaseTypeConstraint DOMHTMLLabelElementHtmlForPropertyInfo = DOMHTMLLabelElementK type AttrGetType DOMHTMLLabelElementHtmlForPropertyInfo = T.Text type AttrLabel DOMHTMLLabelElementHtmlForPropertyInfo = "DOMHTMLLabelElement::html-for" attrGet _ = getDOMHTMLLabelElementHtmlFor attrSet _ = setDOMHTMLLabelElementHtmlFor attrConstruct _ = constructDOMHTMLLabelElementHtmlFor type instance AttributeList DOMHTMLLabelElement = DOMHTMLLabelElementAttributeList type DOMHTMLLabelElementAttributeList = ('[ '("access-key", DOMHTMLElementAccessKeyPropertyInfo), '("attributes", DOMElementAttributesPropertyInfo), '("base-uri", DOMNodeBaseUriPropertyInfo), '("child-element-count", DOMElementChildElementCountPropertyInfo), '("child-nodes", DOMNodeChildNodesPropertyInfo), '("children", DOMHTMLElementChildrenPropertyInfo), '("class-name", DOMElementClassNamePropertyInfo), '("client-height", DOMElementClientHeightPropertyInfo), '("client-left", DOMElementClientLeftPropertyInfo), '("client-top", DOMElementClientTopPropertyInfo), '("client-width", DOMElementClientWidthPropertyInfo), '("content-editable", DOMHTMLElementContentEditablePropertyInfo), '("control", DOMHTMLLabelElementControlPropertyInfo), '("core-object", DOMObjectCoreObjectPropertyInfo), '("dir", DOMHTMLElementDirPropertyInfo), '("draggable", DOMHTMLElementDraggablePropertyInfo), '("first-child", DOMNodeFirstChildPropertyInfo), '("first-element-child", DOMElementFirstElementChildPropertyInfo), '("form", DOMHTMLLabelElementFormPropertyInfo), '("hidden", DOMHTMLElementHiddenPropertyInfo), '("html-for", DOMHTMLLabelElementHtmlForPropertyInfo), '("id", DOMElementIdPropertyInfo), '("inner-html", DOMElementInnerHtmlPropertyInfo), '("inner-text", DOMHTMLElementInnerTextPropertyInfo), '("is-content-editable", DOMHTMLElementIsContentEditablePropertyInfo), '("lang", DOMHTMLElementLangPropertyInfo), '("last-child", DOMNodeLastChildPropertyInfo), '("last-element-child", DOMElementLastElementChildPropertyInfo), '("local-name", DOMNodeLocalNamePropertyInfo), '("namespace-uri", DOMNodeNamespaceUriPropertyInfo), '("next-element-sibling", DOMElementNextElementSiblingPropertyInfo), '("next-sibling", DOMNodeNextSiblingPropertyInfo), '("node-name", DOMNodeNodeNamePropertyInfo), '("node-type", DOMNodeNodeTypePropertyInfo), '("node-value", DOMNodeNodeValuePropertyInfo), '("offset-height", DOMElementOffsetHeightPropertyInfo), '("offset-left", DOMElementOffsetLeftPropertyInfo), '("offset-parent", DOMElementOffsetParentPropertyInfo), '("offset-top", DOMElementOffsetTopPropertyInfo), '("offset-width", DOMElementOffsetWidthPropertyInfo), '("outer-html", DOMElementOuterHtmlPropertyInfo), '("outer-text", DOMHTMLElementOuterTextPropertyInfo), '("owner-document", DOMNodeOwnerDocumentPropertyInfo), '("parent-element", DOMNodeParentElementPropertyInfo), '("parent-node", DOMNodeParentNodePropertyInfo), '("prefix", DOMNodePrefixPropertyInfo), '("previous-element-sibling", DOMElementPreviousElementSiblingPropertyInfo), '("previous-sibling", DOMNodePreviousSiblingPropertyInfo), '("scroll-height", DOMElementScrollHeightPropertyInfo), '("scroll-left", DOMElementScrollLeftPropertyInfo), '("scroll-top", DOMElementScrollTopPropertyInfo), '("scroll-width", DOMElementScrollWidthPropertyInfo), '("spellcheck", DOMHTMLElementSpellcheckPropertyInfo), '("style", DOMElementStylePropertyInfo), '("tab-index", DOMHTMLElementTabIndexPropertyInfo), '("tag-name", DOMElementTagNamePropertyInfo), '("text-content", DOMNodeTextContentPropertyInfo), '("title", DOMHTMLElementTitlePropertyInfo), '("translate", DOMHTMLElementTranslatePropertyInfo), '("webkit-region-overset", DOMElementWebkitRegionOversetPropertyInfo), '("webkitdropzone", DOMHTMLElementWebkitdropzonePropertyInfo)] :: [(Symbol, *)]) type instance SignalList DOMHTMLLabelElement = DOMHTMLLabelElementSignalList type DOMHTMLLabelElementSignalList = ('[ '("notify", GObject.ObjectNotifySignalInfo), '("notify::[property]", GObjectNotifySignalInfo)] :: [(Symbol, *)]) -- method DOMHTMLLabelElement::get_form -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TInterface "WebKit2WebExtension" "DOMHTMLFormElement" -- throws : False -- Skip return : False foreign import ccall "webkit_dom_html_label_element_get_form" webkit_dom_html_label_element_get_form :: Ptr DOMHTMLLabelElement -> -- _obj : TInterface "WebKit2WebExtension" "DOMHTMLLabelElement" IO (Ptr DOMHTMLFormElement) dOMHTMLLabelElementGetForm :: (MonadIO m, DOMHTMLLabelElementK a) => a -> -- _obj m DOMHTMLFormElement dOMHTMLLabelElementGetForm _obj = liftIO $ do let _obj' = unsafeManagedPtrCastPtr _obj result <- webkit_dom_html_label_element_get_form _obj' checkUnexpectedReturnNULL "webkit_dom_html_label_element_get_form" result result' <- (newObject DOMHTMLFormElement) result touchManagedPtr _obj return result' -- method DOMHTMLLabelElement::get_html_for -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TUTF8 -- throws : False -- Skip return : False foreign import ccall "webkit_dom_html_label_element_get_html_for" webkit_dom_html_label_element_get_html_for :: Ptr DOMHTMLLabelElement -> -- _obj : TInterface "WebKit2WebExtension" "DOMHTMLLabelElement" IO CString dOMHTMLLabelElementGetHtmlFor :: (MonadIO m, DOMHTMLLabelElementK a) => a -> -- _obj m T.Text dOMHTMLLabelElementGetHtmlFor _obj = liftIO $ do let _obj' = unsafeManagedPtrCastPtr _obj result <- webkit_dom_html_label_element_get_html_for _obj' checkUnexpectedReturnNULL "webkit_dom_html_label_element_get_html_for" result result' <- cstringToText result freeMem result touchManagedPtr _obj return result' -- method DOMHTMLLabelElement::set_html_for -- method type : OrdinaryMethod -- Args : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- Lengths : [] -- hInArgs : [Arg {argName = "_obj", argType = TInterface "WebKit2WebExtension" "DOMHTMLLabelElement", direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing},Arg {argName = "value", argType = TBasicType TUTF8, direction = DirectionIn, mayBeNull = False, argScope = ScopeTypeInvalid, argClosure = -1, argDestroy = -1, transfer = TransferNothing}] -- returnType : TBasicType TVoid -- throws : False -- Skip return : False foreign import ccall "webkit_dom_html_label_element_set_html_for" webkit_dom_html_label_element_set_html_for :: Ptr DOMHTMLLabelElement -> -- _obj : TInterface "WebKit2WebExtension" "DOMHTMLLabelElement" CString -> -- value : TBasicType TUTF8 IO () dOMHTMLLabelElementSetHtmlFor :: (MonadIO m, DOMHTMLLabelElementK a) => a -> -- _obj T.Text -> -- value m () dOMHTMLLabelElementSetHtmlFor _obj value = liftIO $ do let _obj' = unsafeManagedPtrCastPtr _obj value' <- textToCString value webkit_dom_html_label_element_set_html_for _obj' value' touchManagedPtr _obj freeMem value' return ()