<refentry id="GnomeDbRawGrid">
<refmeta>
<refentrytitle>GnomeDbRawGrid</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>LIBGNOMEDB-4.0 Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>GnomeDbRawGrid</refname><refpurpose>Grid to display and modify data in a GdaDataModel</refpurpose>
</refnamediv>

<refsynopsisdiv><title>Synopsis</title>

<synopsis>



struct      <link linkend="GnomeDbRawGrid-struct">GnomeDbRawGrid</link>;
struct      <link linkend="GnomeDbRawGridClass">GnomeDbRawGridClass</link>;
struct      <link linkend="GnomeDbRawGridPriv">GnomeDbRawGridPriv</link>;
<link linkend="GtkWidget">GtkWidget</link>*  <link linkend="gnome-db-raw-grid-new">gnome_db_raw_grid_new</link>           (<link linkend="GdaDataModel">GdaDataModel</link> *model);
<link linkend="GList">GList</link>*      <link linkend="gnome-db-raw-grid-get-selection">gnome_db_raw_grid_get_selection</link> (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid);
<link linkend="void">void</link>        <link linkend="gnome-db-raw-grid-set-sample-size">gnome_db_raw_grid_set_sample_size</link>
                                            (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid,
                                             <link linkend="gint">gint</link> sample_size);
<link linkend="void">void</link>        <link linkend="gnome-db-raw-grid-set-sample-start">gnome_db_raw_grid_set_sample_start</link>
                                            (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid,
                                             <link linkend="gint">gint</link> sample_start);

</synopsis>
</refsynopsisdiv>

<refsect1>
<title>Object Hierarchy</title>
<synopsis>

  <link linkend="GObject">GObject</link>
   +----<link linkend="GInitiallyUnowned">GInitiallyUnowned</link>
         +----<link linkend="GtkObject">GtkObject</link>
               +----<link linkend="GtkWidget">GtkWidget</link>
                     +----<link linkend="GtkContainer">GtkContainer</link>
                           +----<link linkend="GtkTreeView">GtkTreeView</link>
                                 +----GnomeDbRawGrid
</synopsis>

</refsect1>



<refsect1>
<title>Implemented Interfaces</title>
<para>
GnomeDbRawGrid implements
 <link linkend="AtkImplementorIface">AtkImplementorIface</link>,  <link linkend="GtkBuildable">GtkBuildable</link> and  <link linkend="GnomeDbDataWidget">GnomeDbDataWidget</link>.</para>

</refsect1>


<refsect1>
<title>Properties</title>
<synopsis>

  &quot;<link linkend="GnomeDbRawGrid--global-actions-visible">global-actions-visible</link>&quot; <link linkend="gboolean">gboolean</link>             : Read / Write
  &quot;<link linkend="GnomeDbRawGrid--info-cell-visible">info-cell-visible</link>&quot;    <link linkend="gboolean">gboolean</link>             : Read / Write
  &quot;<link linkend="GnomeDbRawGrid--model">model</link>&quot;                <link linkend="GdaDataModel">GdaDataModel</link>         : Read / Write
</synopsis>
</refsect1>

<refsect1>
<title>Signal Prototypes</title>
<synopsis>

&quot;<link linkend="GnomeDbRawGrid-double-clicked">double-clicked</link>&quot;
            <link linkend="void">void</link>        user_function      (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="gint">gint</link> arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GnomeDbRawGrid-populate-popup">populate-popup</link>&quot;
            <link linkend="void">void</link>        user_function      (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="GtkMenu">GtkMenu</link> *arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);
&quot;<link linkend="GnomeDbRawGrid-selection-changed">selection-changed</link>&quot;
            <link linkend="void">void</link>        user_function      (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="gboolean">gboolean</link> arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);
</synopsis>
</refsect1>


<refsect1>
<title>Description</title>
<para>
This widget only contains data, it has no decoration, or button to change the displayed row,
or any indicator about the current displayed row or the total number of rows. To have a complete
grid widget, see the <link linkend="GnomeDbGrid"><type>GnomeDbGrid</type></link> widget.
</para>
<para>
This widget is itself a <link linkend="GtkTreeView"><type>GtkTreeView</type></link> widget.
</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="GnomeDbRawGrid-struct"/>struct GnomeDbRawGrid</title>
<indexterm><primary>GnomeDbRawGrid</primary></indexterm><programlisting>struct GnomeDbRawGrid;</programlisting>
<para>

</para></refsect2>
<refsect2>
<title><anchor id="GnomeDbRawGridClass"/>struct GnomeDbRawGridClass</title>
<indexterm><primary>GnomeDbRawGridClass</primary></indexterm><programlisting>struct GnomeDbRawGridClass {

	GtkTreeViewClass        parent_class;

	void             (* selection_changed) (GnomeDbRawGrid *grid, gboolean row_selected);
	void             (* double_clicked)    (GnomeDbRawGrid *grid, gint row);
        void             (* populate_popup)    (GnomeDbRawGrid *grid, GtkMenu *menu);
};
</programlisting>
<para>

</para></refsect2>
<refsect2>
<title><anchor id="GnomeDbRawGridPriv"/>struct GnomeDbRawGridPriv</title>
<indexterm><primary>GnomeDbRawGridPriv</primary></indexterm><programlisting>struct GnomeDbRawGridPriv;</programlisting>
<para>

</para></refsect2>
<refsect2>
<title><anchor id="gnome-db-raw-grid-new"/>gnome_db_raw_grid_new ()</title>
<indexterm><primary>gnome_db_raw_grid_new</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link>*  gnome_db_raw_grid_new           (<link linkend="GdaDataModel">GdaDataModel</link> *model);</programlisting>
<para>
Creates a new <link linkend="GnomeDbRawGrid"><type>GnomeDbRawGrid</type></link> widget suitable to display the data in <parameter>model</parameter></para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>model</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GdaDataModel"><type>GdaDataModel</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the new widget
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gnome-db-raw-grid-get-selection"/>gnome_db_raw_grid_get_selection ()</title>
<indexterm><primary>gnome_db_raw_grid_get_selection</primary></indexterm><programlisting><link linkend="GList">GList</link>*      gnome_db_raw_grid_get_selection (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid);</programlisting>
<para>
Returns the list of the currently selected rows in a <link linkend="GnomeDbRawGrid"><type>GnomeDbRawGrid</type></link> widget. 
The returned value is a list of integers, which represent each of the selected rows.
</para>
<para>
If new rows have been inserted, then those new rows will have a row number equal to -1.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>grid</parameter>&nbsp;:</term>
<listitem><simpara> a <link linkend="GnomeDbRawGrid"><type>GnomeDbRawGrid</type></link> widget
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a new list, should be freed (by calling g_list_free) when no longer needed.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gnome-db-raw-grid-set-sample-size"/>gnome_db_raw_grid_set_sample_size ()</title>
<indexterm><primary>gnome_db_raw_grid_set_sample_size</primary></indexterm><programlisting><link linkend="void">void</link>        gnome_db_raw_grid_set_sample_size
                                            (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid,
                                             <link linkend="gint">gint</link> sample_size);</programlisting>
<para>
</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>grid</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>sample_size</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gnome-db-raw-grid-set-sample-start"/>gnome_db_raw_grid_set_sample_start ()</title>
<indexterm><primary>gnome_db_raw_grid_set_sample_start</primary></indexterm><programlisting><link linkend="void">void</link>        gnome_db_raw_grid_set_sample_start
                                            (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *grid,
                                             <link linkend="gint">gint</link> sample_start);</programlisting>
<para>
</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>grid</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>sample_start</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>
<refsect1>
<title>Properties</title>
<variablelist>
<varlistentry><term><anchor id="GnomeDbRawGrid--global-actions-visible"/>&quot;<literal>global-actions-visible</literal>&quot; (<link linkend="gboolean">gboolean</link> : Read / Write)</term>
<listitem>
<para>Global Actions visible.</para>
</listitem></varlistentry>
<varlistentry><term><anchor id="GnomeDbRawGrid--info-cell-visible"/>&quot;<literal>info-cell-visible</literal>&quot; (<link linkend="gboolean">gboolean</link> : Read / Write)</term>
<listitem>
<para>Info cell visible.</para>
</listitem></varlistentry>
<varlistentry><term><anchor id="GnomeDbRawGrid--model"/>&quot;<literal>model</literal>&quot; (<link linkend="GdaDataModel">GdaDataModel</link> : Read / Write)</term>
<listitem>
<para></para>
</listitem></varlistentry>

</variablelist>
</refsect1>

<refsect1>
<title>Signals</title>
<refsect2><title><anchor id="GnomeDbRawGrid-double-clicked"/>The &quot;double-clicked&quot; signal</title>
<programlisting><link linkend="void">void</link>        user_function                  (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="gint">gint</link> arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>dbrawgrid</parameter>&nbsp;:</term>
<listitem><simpara>the object which received the signal.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>arg1</parameter>&nbsp;:</term>
<listitem><simpara>

</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&nbsp;:</term>
<listitem><simpara>user data set when the signal handler was connected.</simpara></listitem></varlistentry>
</variablelist></refsect2><refsect2><title><anchor id="GnomeDbRawGrid-populate-popup"/>The &quot;populate-popup&quot; signal</title>
<programlisting><link linkend="void">void</link>        user_function                  (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="GtkMenu">GtkMenu</link> *arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>dbrawgrid</parameter>&nbsp;:</term>
<listitem><simpara>the object which received the signal.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>arg1</parameter>&nbsp;:</term>
<listitem><simpara>

</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&nbsp;:</term>
<listitem><simpara>user data set when the signal handler was connected.</simpara></listitem></varlistentry>
</variablelist></refsect2><refsect2><title><anchor id="GnomeDbRawGrid-selection-changed"/>The &quot;selection-changed&quot; signal</title>
<programlisting><link linkend="void">void</link>        user_function                  (<link linkend="GnomeDbRawGrid">GnomeDbRawGrid</link> *dbrawgrid,
                                            <link linkend="gboolean">gboolean</link> arg1,
                                            <link linkend="gpointer">gpointer</link> user_data);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>dbrawgrid</parameter>&nbsp;:</term>
<listitem><simpara>the object which received the signal.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>arg1</parameter>&nbsp;:</term>
<listitem><simpara>

</simpara></listitem></varlistentry>
<varlistentry><term><parameter>user_data</parameter>&nbsp;:</term>
<listitem><simpara>user data set when the signal handler was connected.</simpara></listitem></varlistentry>
</variablelist></refsect2>
</refsect1>


<refsect1>
<title>See Also</title>
<para>
The <link linkend="GnomeDbRawForm"><type>GnomeDbRawForm</type></link> widget which displays the same information but as form instead of a grid.
</para>
</refsect1>

</refentry>
