Gtk2_IndexedComboBox
[ class tree: Gtk2_IndexedComboBox ] [ index: Gtk2_IndexedComboBox ] [ all elements ]

Class: Gtk2_IndexedComboBox_Model

Source Location: /Gtk2_IndexedComboBox-0.2.0/Gtk2/IndexedComboBox/Model.php

Class Overview

GtkListStore
   |
   --Gtk2_IndexedComboBox_Model

Indexed Gtk2 combo box model. Can be used stand-alone e.g. as model for a GtkComboBox from a glade file.


Author(s):

Version:

  • CVS: $Id: IndexedComboBox.php,v 1.3 2006/04/05 07:13:27 cweiske Exp $

Methods


Inherited Variables

Inherited Methods


Class Details

[line 14]
Indexed Gtk2 combo box model. Can be used stand-alone e.g. as model for a GtkComboBox from a glade file.

Both key and values can be strings or integers.

  • Author: Christian Weiske <cweiske@php.net>
  • Version: CVS: $Id: IndexedComboBox.php,v 1.3 2006/04/05 07:13:27 cweiske Exp $
  • License: LGPL


[ Top ]


Method Detail

__construct (Constructor)   [line 21]

Gtk2_IndexedComboBox_Model __construct( [array $arData = null])

Constructor.
  • Access: public

Parameters:

array   $arData   —  If wished, you can set the initial data here.

[ Top ]

append   [line 37]

void append( mixed $strId, [string $strValue = null])

Appends a single key/value pair to the list.
  • Access: public

Parameters:

mixed   $strId   —  (string) id to append, or an array to append
string   $strValue   —  The value to append

[ Top ]

appendArray   [line 230]

void appendArray( $arData)

  • Access: public

Parameters:

   $arData   — 

[ Top ]

append_array   [line 53]

void append_array( array $arData)

Appends an array (key and value) as data to the store.
  • Access: public

Parameters:

array   $arData   —  The array to append

[ Top ]

getArray   [line 236]

void getArray( )

  • Access: public

[ Top ]

get_array   [line 101]

array get_array( )

Returns an array with all key/value pairs.
  • Return: Array with key/value pairs in the model
  • Access: public

[ Top ]

get_key   [line 69]

string get_key( GtkTreeIter $iter)

Returns the key/id of the given iter.

If $iter is NULL, this method returns NULL.

  • Return: The id/key of the selected entry
  • Access: public

Parameters:

GtkTreeIter   $iter   —  Iterator whose key shall be gotten.

[ Top ]

get_text   [line 86]

string get_text( GtkTreeIter $iter)

Returns the string of the given iter.

If $iter is NULL, this method returns NULL.

  • Return: The string value of the selected entry
  • Access: public

Parameters:

GtkTreeIter   $iter   —  Iterator whose string shall be gotten.

[ Top ]

insert   [line 125]

void insert( int $nPosition, mixed $strId, [string $strValue = null])

Inserts a single key/value pair (or an array) at a certain position into the list.
  • Access: public

Parameters:

int   $nPosition   —  The position to insert the values at
mixed   $strId   —  (string) id to append, or array to append
string   $strValue   —  The value to append

[ Top ]

insertArray   [line 242]

void insertArray( $nPosition, $arData)

  • Access: public

Parameters:

   $nPosition   — 
   $arData   — 

[ Top ]

insert_array   [line 142]

void insert_array( int $nPosition, array $arData)

Inserts an array (key and value) at a certain position into the list.
  • Access: public

Parameters:

int   $nPosition   —  The position to insert the array at
array   $arData   —  The array to append

[ Top ]

prepend   [line 157]

void prepend( mixed $strId, [string $strValue = null])

Prepends a single key/value pair to the list.
  • Access: public

Parameters:

mixed   $strId   —  (string) id to prepend, or array to prepend
string   $strValue   —  The value to append

[ Top ]

prependArray   [line 248]

void prependArray( $arData)

  • Access: public

Parameters:

   $arData   — 

[ Top ]

prepend_array   [line 173]

void prepend_array( array $arData)

Prepends an array (key and value) at the beginning of the store
  • Access: public

Parameters:

array   $arData   —  The array to append

[ Top ]

removeKey   [line 254]

void removeKey( $strId)

  • Access: public

Parameters:

   $strId   — 

[ Top ]

remove_key   [line 190]

boolean remove_key( string $strId)

Removes the first entry with the given key from the list.
  • Return: True if an entry has been deleted
  • Access: public

Parameters:

string   $strId   —  The key of the entry to remove

[ Top ]

setArray   [line 260]

void setArray( $arData)

  • Access: public

Parameters:

   $arData   — 

[ Top ]

set_array   [line 216]

void set_array( array $arData)

Sets an array (key and value) as data into the store.

Clears any previous entries.

  • Access: public

Parameters:

array   $arData   —  The array to set

[ Top ]


Documentation generated on Mon, 11 Mar 2019 14:39:45 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.