📄 gparamspecs.h
字号:
/* GObject - GLib Type, Object, Parameter and Signal Library * Copyright (C) 1997-1999, 2000-2001 Tim Janik and Red Hat, Inc. * * This library 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 2 of the License, or (at your option) any later version. * * This library 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 library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place, Suite 330, * Boston, MA 02111-1307, USA. * * gparamspecs.h: GLib default param specs */#if !defined (__GLIB_GOBJECT_H_INSIDE__) && !defined (GOBJECT_COMPILATION)#error "Only <glib-object.h> can be included directly."#endif#ifndef __G_PARAMSPECS_H__#define __G_PARAMSPECS_H__#include <gobject/gvalue.h>#include <gobject/genums.h>#include <gobject/gboxed.h>#include <gobject/gobject.h>G_BEGIN_DECLS/* --- type macros --- *//** * G_TYPE_PARAM_CHAR: * * The #GType of #GParamSpecChar. */#define G_TYPE_PARAM_CHAR (g_param_spec_types[0])/** * G_IS_PARAM_SPEC_CHAR: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_CHAR. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_CHAR(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_CHAR))/** * G_PARAM_SPEC_CHAR: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecChar. */#define G_PARAM_SPEC_CHAR(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_CHAR, GParamSpecChar))/** * G_TYPE_PARAM_UCHAR: * * The #GType of #GParamSpecUChar. */#define G_TYPE_PARAM_UCHAR (g_param_spec_types[1])/** * G_IS_PARAM_SPEC_UCHAR: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_UCHAR. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_UCHAR(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_UCHAR))/** * G_PARAM_SPEC_UCHAR: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecUChar. */#define G_PARAM_SPEC_UCHAR(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_UCHAR, GParamSpecUChar))/** * G_TYPE_PARAM_BOOLEAN: * * The #GType of #GParamSpecBoolean. */#define G_TYPE_PARAM_BOOLEAN (g_param_spec_types[2])/** * G_IS_PARAM_SPEC_BOOLEAN: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_BOOLEAN. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_BOOLEAN(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_BOOLEAN))/** * G_PARAM_SPEC_BOOLEAN: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecBoolean. */#define G_PARAM_SPEC_BOOLEAN(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_BOOLEAN, GParamSpecBoolean))/** * G_TYPE_PARAM_INT: * * The #GType of #GParamSpecInt. */#define G_TYPE_PARAM_INT (g_param_spec_types[3])/** * G_IS_PARAM_SPEC_INT: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_INT. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_INT(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_INT))/** * G_PARAM_SPEC_INT: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecInt. */#define G_PARAM_SPEC_INT(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_INT, GParamSpecInt))/** * G_TYPE_PARAM_UINT: * * The #GType of #GParamSpecUInt. */#define G_TYPE_PARAM_UINT (g_param_spec_types[4])/** * G_IS_PARAM_SPEC_UINT: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_UINT. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_UINT(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_UINT))/** * G_PARAM_SPEC_UINT: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecUInt. */#define G_PARAM_SPEC_UINT(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_UINT, GParamSpecUInt))/** * G_TYPE_PARAM_LONG: * * The #GType of #GParamSpecLong. */#define G_TYPE_PARAM_LONG (g_param_spec_types[5])/** * G_IS_PARAM_SPEC_LONG: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_LONG. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_LONG(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_LONG))/** * G_PARAM_SPEC_LONG: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecLong. */#define G_PARAM_SPEC_LONG(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_LONG, GParamSpecLong))/** * G_TYPE_PARAM_ULONG: * * The #GType of #GParamSpecULong. */#define G_TYPE_PARAM_ULONG (g_param_spec_types[6])/** * G_IS_PARAM_SPEC_ULONG: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_ULONG. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_ULONG(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_ULONG))/** * G_PARAM_SPEC_ULONG: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecULong. */#define G_PARAM_SPEC_ULONG(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_ULONG, GParamSpecULong))/** * G_TYPE_PARAM_INT64: * * The #GType of #GParamSpecInt64. */#define G_TYPE_PARAM_INT64 (g_param_spec_types[7])/** * G_IS_PARAM_SPEC_INT64: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_INT64. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_INT64(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_INT64))/** * G_PARAM_SPEC_INT64: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecInt64. */#define G_PARAM_SPEC_INT64(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_INT64, GParamSpecInt64))/** * G_TYPE_PARAM_UINT64: * * The #GType of #GParamSpecUInt64. */#define G_TYPE_PARAM_UINT64 (g_param_spec_types[8])/** * G_IS_PARAM_SPEC_UINT64: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_UINT64. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_UINT64(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_UINT64))/** * G_PARAM_SPEC_UINT64: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecUInt64. */#define G_PARAM_SPEC_UINT64(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_UINT64, GParamSpecUInt64))/** * G_TYPE_PARAM_UNICHAR: * * The #GType of #GParamSpecUnichar. */#define G_TYPE_PARAM_UNICHAR (g_param_spec_types[9])/** * G_PARAM_SPEC_UNICHAR: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecUnichar. */#define G_PARAM_SPEC_UNICHAR(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_UNICHAR, GParamSpecUnichar))/** * G_IS_PARAM_SPEC_UNICHAR: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_UNICHAR. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_UNICHAR(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_UNICHAR))/** * G_TYPE_PARAM_ENUM: * * The #GType of #GParamSpecEnum. */#define G_TYPE_PARAM_ENUM (g_param_spec_types[10])/** * G_IS_PARAM_SPEC_ENUM: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_ENUM. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_ENUM(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_ENUM))/** * G_PARAM_SPEC_ENUM: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecEnum. */#define G_PARAM_SPEC_ENUM(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_ENUM, GParamSpecEnum))/** * G_TYPE_PARAM_FLAGS: * * The #GType of #GParamSpecFlags. */#define G_TYPE_PARAM_FLAGS (g_param_spec_types[11])/** * G_IS_PARAM_SPEC_FLAGS: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_FLAGS. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_FLAGS(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_FLAGS))/** * G_PARAM_SPEC_FLAGS: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecFlags. */#define G_PARAM_SPEC_FLAGS(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_FLAGS, GParamSpecFlags))/** * G_TYPE_PARAM_FLOAT: * * The #GType of #GParamSpecFloat. */#define G_TYPE_PARAM_FLOAT (g_param_spec_types[12])/** * G_IS_PARAM_SPEC_FLOAT: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_FLOAT. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_FLOAT(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_FLOAT))/** * G_PARAM_SPEC_FLOAT: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecFloat. */#define G_PARAM_SPEC_FLOAT(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_FLOAT, GParamSpecFloat))/** * G_TYPE_PARAM_DOUBLE: * * The #GType of #GParamSpecDouble. */#define G_TYPE_PARAM_DOUBLE (g_param_spec_types[13])/** * G_IS_PARAM_SPEC_DOUBLE: * @pspec: a valid #GParamSpec instance * * Checks whether the given #GParamSpec is of type %G_TYPE_PARAM_DOUBLE. * * Returns: %TRUE on success. */#define G_IS_PARAM_SPEC_DOUBLE(pspec) (G_TYPE_CHECK_INSTANCE_TYPE ((pspec), G_TYPE_PARAM_DOUBLE))/** * G_PARAM_SPEC_DOUBLE: * @pspec: a valid #GParamSpec instance * * Cast a #GParamSpec instance into a #GParamSpecDouble. */#define G_PARAM_SPEC_DOUBLE(pspec) (G_TYPE_CHECK_INSTANCE_CAST ((pspec), G_TYPE_PARAM_DOUBLE, GParamSpecDouble))/** * G_TYPE_PARAM_STRING: * * The #GType of #GParamSpecString. */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -