This file is indexed.

/usr/share/perl5/Gtk2/TreeSortable.pod is in libgtk2-perl-doc 2:1.2499-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
=head1 NAME

Gtk2::TreeSortable - wrapper for GtkTreeSortable

=cut

=head1 HIERARCHY

  Glib::Interface
  +----Gtk2::TreeSortable



=cut


=head1 METHODS

=head2 $sortable-E<gt>B<set_default_sort_func> ($sort_func, $user_data=undef)

=over

=item * $sort_func (scalar) 

=item * $user_data (scalar) 

=back

=head2 boolean = $sortable-E<gt>B<has_default_sort_func> 

=head2 $sortable-E<gt>B<sort_column_changed> 

=head2 (sort_column_id, order) = $sortable->B<get_sort_column_id>

Returns sort_column_id, an integer and order, a Gtk2::SortType.

=head2 $sortable-E<gt>B<set_sort_column_id> ($sort_column_id, $order)

=over

=item * $sort_column_id (integer) 

=item * $order (Gtk2::SortType) 

=back

=head2 $sortable-E<gt>B<set_sort_func> ($sort_column_id, $sort_func, $user_data=undef)

=over

=item * $sort_column_id (integer) 

=item * $sort_func (scalar) 

=item * $user_data (scalar) 

=back



=cut

=for position post_methods

=head1 IMPLEMENTING THE I<GtkTreeSortable> INTERACE

If you want your custom tree model to be sortable, you need to implement the
I<GtkTreeSortable> interface.  Just like with other interfaces, this boils down
to announcing that your subclass implements the interface and providing a few
virtual methods.  The former is achieved by adding C<Gtk2::TreeSortable> to the
C<interfaces> key.  For example:

  package MyModel;
  use Gtk2;
  use Glib::Object::Subclass
      Glib::Object::,
      interfaces => [ Gtk2::TreeModel::, Gtk2::TreeSortable:: ],
      ;

The virtual methods you need to implement are listed below.

=head2 VIRTUAL METHODS

These virtual methods are called by perl when gtk+ attempts to modify the
sorting behavior of your model.  Implement them in your model's package.  Note
that we don't provide a wrapper for I<sort_column_changed> because there is a
signal for it, which means you can use the normal signal overriding mechanism
documented in L<Glib::Object::Subclass>.

=over

=item (is_not_special, id, order) = GET_SORT_COLUMN_ID ($model)

Returns a boolean indicating whether the column is a special or normal one, its
id and its sorting order.

=item SET_SORT_COLUMN_ID ($list, $id, $order)

Sets the sort column to the one specified by I<$id> and the sorting order to
I<$order>.

=item SET_SORT_FUNC ($list, $id, $func, $data)

Sets the function that is to be used for sorting the column I<$id>.

=item SET_DEFAULT_SORT_FUNC ($list, $func, $data)

Sets the function that is to be used for sorting columns that don't have a
sorting function attached to them.

The I<$func> and I<$data> arguments passed to these two methods should be
treated as blackboxes.  They are generic containers for some callback that is
to be invoked whenever you want to compare two tree iters.  When you call them,
make sure to always pass I<$data>.  For example:

  $retval = $func->($list, $a, $b, $data);

=item bool = HAS_DEFAULT_SORT_FUNC ($list)

Returns a bool indicating whether I<$list> has a default sorting function.

=back

=cut




=head1 SIGNALS

=over

=item B<sort-column-changed> (Gtk2::TreeSortable)

=back



=cut


=head1 ENUMS AND FLAGS

=head2 enum Gtk2::SortType

=over

=item * 'ascending' / 'GTK_SORT_ASCENDING'

=item * 'descending' / 'GTK_SORT_DESCENDING'

=back




=cut


=head1 SEE ALSO

L<Gtk2>, L<Glib::Interface>


=cut


=head1 COPYRIGHT

Copyright (C) 2003-2011 by the gtk2-perl team.

This software is licensed under the LGPL.  See L<Gtk2> for a full notice.



=cut