GimpUi.PageSelector¶
- Subclasses:
 None
Methods¶
- Inherited:
 Gtk.Box (14), Gtk.Container (35), Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10), Gtk.Orientable (2)
- Structs:
 Gtk.ContainerClass (5), Gtk.WidgetClass (12), GObject.ObjectClass (5)
class  | 
  | 
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
Virtual Methods¶
Properties¶
- Inherited:
 Gtk.Box (3), Gtk.Container (3), Gtk.Widget (39), Gtk.Orientable (1)
Name  | 
Type  | 
Flags  | 
Short Description  | 
|---|---|---|---|
r/w  | 
The number of pages to open  | 
||
r/w  | 
the target to open to  | 
Child Properties¶
- Inherited:
 
Style Properties¶
- Inherited:
 
Signals¶
- Inherited:
 
Name  | 
Short Description  | 
|---|---|
The “activate” signal on   | 
|
This signal is emitted whenever the set of selected pages changes.  | 
Fields¶
- Inherited:
 
Class Details¶
- class GimpUi.PageSelector(*args, **kwargs)¶
 - Bases:
 - Abstract:
 No
- Structure:
 
Use this for example for specifying what pages to import from a PDF or PS document.
- classmethod new()¶
 - Returns:
 Pointer to the new
GimpUi.PageSelectorwidget.- Return type:
 
Creates a new
GimpUi.PageSelectorwidget.New in version 2.4.
- get_n_pages()¶
 - Returns:
 the number of pages in the document to open.
- Return type:
 
New in version 2.4.
- get_page_label(page_no)¶
 - Parameters:
 page_no (
int) – The number of the page to get the thumbnail for.- Returns:
 The page’s label, or
Noneif none is set. This is a newly allocated string that should beGLib.free()’d when no longer needed.- Return type:
 
New in version 2.4.
- get_page_thumbnail(page_no)¶
 - Parameters:
 page_no (
int) – The number of the page to get the thumbnail for.- Returns:
 The page’s thumbnail, or
Noneif none is set. The returned pixbuf is owned byGimpUi.PageSelectorand must not be unref’ed when no longer needed.- Return type:
 
New in version 2.4.
- get_selected_pages()¶
 - Returns:
 A sorted array of page numbers of selected pages. Use
GLib.free() if you don’t need the array any longer- Return type:
 [
int]
New in version 2.4.
- get_selected_range()¶
 - Returns:
 A newly allocated string representing the set of selected pages. See
GimpUi.PageSelector.select_range() for the format of the string.- Return type:
 
New in version 2.4.
- get_target()¶
 - Returns:
 How the selected pages should be opened.
- Return type:
 
New in version 2.4.
- page_is_selected(page_no)¶
 - Parameters:
 page_no (
int) – The number of the page to check.- Returns:
 - Return type:
 
New in version 2.4.
- select_all()¶
 Selects all pages.
New in version 2.4.
- select_page(page_no)¶
 - Parameters:
 page_no (
int) – The number of the page to select.
Adds a page to the selection.
New in version 2.4.
- select_range(range)¶
 - Parameters:
 range (
str) – A string representing the set of selected pages.
Selects the pages described by range. The range string is a user-editable list of pages and ranges, e.g. “1,3,5-7,9-12,14”. Note that the page numbering in the range string starts with 1, not 0.
Invalid pages and ranges will be silently ignored, duplicate and overlapping pages and ranges will be merged.
New in version 2.4.
- set_n_pages(n_pages)¶
 - Parameters:
 n_pages (
int) – The number of pages.
Sets the number of pages in the document to open.
New in version 2.4.
- set_page_label(page_no, label)¶
 - 
Sets the label of the specified page.
New in version 2.4.
 
- set_page_thumbnail(page_no, thumbnail)¶
 - Parameters:
 page_no (
int) – The number of the page to set the thumbnail for.thumbnail (
GdkPixbuf.Pixbuf) – The thumbnail pixbuf.
Sets the thumbnail for given page_no. A default “page” icon will be used if no page thumbnail is set.
New in version 2.4.
- set_target(target)¶
 - Parameters:
 target (
GimpUi.PageSelectorTarget) – How to open the selected pages.
New in version 2.4.
- unselect_all()¶
 Unselects all pages.
New in version 2.4.
Signal Details¶
- GimpUi.PageSelector.signals.activate(page_selector)¶
 - Signal Name:
 activate- Flags:
 - Parameters:
 page_selector (
GimpUi.PageSelector) – The object which received the signal
The “activate” signal on
GimpUi.PageSelectoris an action signal. It is emitted when a user double-clicks an item in the page selection.New in version 2.4.
- GimpUi.PageSelector.signals.selection_changed(page_selector)¶
 - Signal Name:
 selection-changed- Flags:
 - Parameters:
 page_selector (
GimpUi.PageSelector) – The object which received the signal
This signal is emitted whenever the set of selected pages changes.
New in version 2.4.
Property Details¶
- GimpUi.PageSelector.props.n_pages¶
 - 
The number of pages of the document to open.
New in version 2.4.
 
- GimpUi.PageSelector.props.target¶
 - Name:
 target- Type:
 - Default Value:
 - Flags:
 
The target to open the document to.
New in version 2.4.