gtk4/auto/
tree_view_column.rs

1// This file was generated by gir (https://github.com/gtk-rs/gir)
2// from gir-files (https://github.com/gtk-rs/gir-files)
3// DO NOT EDIT
4#![allow(deprecated)]
5
6use crate::{
7    ffi, Buildable, CellArea, CellLayout, CellRenderer, SortType, TreeIter, TreeModel,
8    TreeViewColumnSizing, Widget,
9};
10use glib::{
11    object::ObjectType as _,
12    prelude::*,
13    signal::{connect_raw, SignalHandlerId},
14    translate::*,
15};
16use std::boxed::Box as Box_;
17
18glib::wrapper! {
19    /// Use [`ColumnView`][crate::ColumnView] and [`ColumnViewColumn`][crate::ColumnViewColumn]
20    ///   instead of [`TreeView`][crate::TreeView] to show a tabular list
21    /// A visible column in a [`TreeView`][crate::TreeView] widget
22    ///
23    /// The [`TreeViewColumn`][crate::TreeViewColumn] object represents a visible column in a [`TreeView`][crate::TreeView] widget.
24    /// It allows to set properties of the column header, and functions as a holding pen
25    /// for the cell renderers which determine how the data in the column is displayed.
26    ///
27    /// Please refer to the [tree widget conceptual overview](section-tree-widget.html)
28    /// for an overview of all the objects and data types related to the tree widget and
29    /// how they work together, and to the [`TreeView`][crate::TreeView] documentation for specifics
30    /// about the CSS node structure for treeviews and their headers.
31    ///
32    /// ## Properties
33    ///
34    ///
35    /// #### `alignment`
36    ///  Readable | Writeable
37    ///
38    ///
39    /// #### `cell-area`
40    ///  The [`CellArea`][crate::CellArea] used to layout cell renderers for this column.
41    ///
42    /// If no area is specified when creating the tree view column with gtk_tree_view_column_new_with_area()
43    /// a horizontally oriented [`CellAreaBox`][crate::CellAreaBox] will be used.
44    ///
45    /// Readable | Writeable | Construct Only
46    ///
47    ///
48    /// #### `clickable`
49    ///  Readable | Writeable
50    ///
51    ///
52    /// #### `expand`
53    ///  Readable | Writeable
54    ///
55    ///
56    /// #### `fixed-width`
57    ///  Readable | Writeable
58    ///
59    ///
60    /// #### `max-width`
61    ///  Readable | Writeable
62    ///
63    ///
64    /// #### `min-width`
65    ///  Readable | Writeable
66    ///
67    ///
68    /// #### `reorderable`
69    ///  Readable | Writeable
70    ///
71    ///
72    /// #### `resizable`
73    ///  Readable | Writeable
74    ///
75    ///
76    /// #### `sizing`
77    ///  Readable | Writeable
78    ///
79    ///
80    /// #### `sort-column-id`
81    ///  Logical sort column ID this column sorts on when selected for sorting. Setting the sort column ID makes the column header
82    /// clickable. Set to -1 to make the column unsortable.
83    ///
84    /// Readable | Writeable
85    ///
86    ///
87    /// #### `sort-indicator`
88    ///  Readable | Writeable
89    ///
90    ///
91    /// #### `sort-order`
92    ///  Readable | Writeable
93    ///
94    ///
95    /// #### `spacing`
96    ///  Readable | Writeable
97    ///
98    ///
99    /// #### `title`
100    ///  Readable | Writeable
101    ///
102    ///
103    /// #### `visible`
104    ///  Readable | Writeable
105    ///
106    ///
107    /// #### `widget`
108    ///  Readable | Writeable
109    ///
110    ///
111    /// #### `width`
112    ///  Readable
113    ///
114    ///
115    /// #### `x-offset`
116    ///  Readable
117    ///
118    /// ## Signals
119    ///
120    ///
121    /// #### `clicked`
122    ///  Emitted when the column's header has been clicked.
123    ///
124    ///
125    ///
126    /// # Implements
127    ///
128    /// [`trait@glib::ObjectExt`], [`BuildableExt`][trait@crate::prelude::BuildableExt], [`CellLayoutExt`][trait@crate::prelude::CellLayoutExt], [`CellLayoutExtManual`][trait@crate::prelude::CellLayoutExtManual]
129    #[doc(alias = "GtkTreeViewColumn")]
130    pub struct TreeViewColumn(Object<ffi::GtkTreeViewColumn>) @implements Buildable, CellLayout;
131
132    match fn {
133        type_ => || ffi::gtk_tree_view_column_get_type(),
134    }
135}
136
137impl TreeViewColumn {
138    /// Creates a new [`TreeViewColumn`][crate::TreeViewColumn].
139    ///
140    /// # Deprecated since 4.10
141    ///
142    /// Use GtkColumnView instead
143    ///
144    /// # Returns
145    ///
146    /// A newly created [`TreeViewColumn`][crate::TreeViewColumn].
147    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
148    #[allow(deprecated)]
149    #[doc(alias = "gtk_tree_view_column_new")]
150    pub fn new() -> TreeViewColumn {
151        assert_initialized_main_thread!();
152        unsafe { from_glib_none(ffi::gtk_tree_view_column_new()) }
153    }
154
155    /// Creates a new [`TreeViewColumn`][crate::TreeViewColumn] using @area to render its cells.
156    ///
157    /// # Deprecated since 4.10
158    ///
159    /// Use GtkColumnView instead
160    /// ## `area`
161    /// the [`CellArea`][crate::CellArea] that the newly created column should use to layout cells.
162    ///
163    /// # Returns
164    ///
165    /// A newly created [`TreeViewColumn`][crate::TreeViewColumn].
166    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
167    #[allow(deprecated)]
168    #[doc(alias = "gtk_tree_view_column_new_with_area")]
169    #[doc(alias = "new_with_area")]
170    pub fn with_area(area: &impl IsA<CellArea>) -> TreeViewColumn {
171        skip_assert_initialized!();
172        unsafe {
173            from_glib_none(ffi::gtk_tree_view_column_new_with_area(
174                area.as_ref().to_glib_none().0,
175            ))
176        }
177    }
178
179    // rustdoc-stripper-ignore-next
180    /// Creates a new builder-pattern struct instance to construct [`TreeViewColumn`] objects.
181    ///
182    /// This method returns an instance of [`TreeViewColumnBuilder`](crate::builders::TreeViewColumnBuilder) which can be used to create [`TreeViewColumn`] objects.
183    pub fn builder() -> TreeViewColumnBuilder {
184        TreeViewColumnBuilder::new()
185    }
186
187    /// Adds an attribute mapping to the list in @self.
188    ///
189    /// The @column is the
190    /// column of the model to get a value from, and the @attribute is the
191    /// parameter on @cell_renderer to be set from the value. So for example
192    /// if column 2 of the model contains strings, you could have the
193    /// “text” attribute of a [`CellRendererText`][crate::CellRendererText] get its values from
194    /// column 2.
195    ///
196    /// # Deprecated since 4.10
197    ///
198    /// Use GtkColumnView instead
199    /// ## `cell_renderer`
200    /// the [`CellRenderer`][crate::CellRenderer] to set attributes on
201    /// ## `attribute`
202    /// An attribute on the renderer
203    /// ## `column`
204    /// The column position on the model to get the attribute from.
205    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
206    #[allow(deprecated)]
207    #[doc(alias = "gtk_tree_view_column_add_attribute")]
208    pub fn add_attribute(
209        &self,
210        cell_renderer: &impl IsA<CellRenderer>,
211        attribute: &str,
212        column: i32,
213    ) {
214        unsafe {
215            ffi::gtk_tree_view_column_add_attribute(
216                self.to_glib_none().0,
217                cell_renderer.as_ref().to_glib_none().0,
218                attribute.to_glib_none().0,
219                column,
220            );
221        }
222    }
223
224    /// Obtains the horizontal position and size of a cell in a column.
225    ///
226    /// If the  cell is not found in the column, @start_pos and @width
227    /// are not changed and [`false`] is returned.
228    ///
229    /// # Deprecated since 4.10
230    ///
231    /// Use GtkColumnView instead
232    /// ## `cell_renderer`
233    /// a [`CellRenderer`][crate::CellRenderer]
234    ///
235    /// # Returns
236    ///
237    /// [`true`] if @cell belongs to @self
238    ///
239    /// ## `x_offset`
240    /// return location for the horizontal
241    ///   position of @cell within @self
242    ///
243    /// ## `width`
244    /// return location for the width of @cell
245    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
246    #[allow(deprecated)]
247    #[doc(alias = "gtk_tree_view_column_cell_get_position")]
248    pub fn cell_get_position(&self, cell_renderer: &impl IsA<CellRenderer>) -> Option<(i32, i32)> {
249        unsafe {
250            let mut x_offset = std::mem::MaybeUninit::uninit();
251            let mut width = std::mem::MaybeUninit::uninit();
252            let ret = from_glib(ffi::gtk_tree_view_column_cell_get_position(
253                self.to_glib_none().0,
254                cell_renderer.as_ref().to_glib_none().0,
255                x_offset.as_mut_ptr(),
256                width.as_mut_ptr(),
257            ));
258            if ret {
259                Some((x_offset.assume_init(), width.assume_init()))
260            } else {
261                None
262            }
263        }
264    }
265
266    /// Obtains the width and height needed to render the column.  This is used
267    /// primarily by the [`TreeView`][crate::TreeView].
268    ///
269    /// # Deprecated since 4.10
270    ///
271    /// Use GtkColumnView instead
272    ///
273    /// # Returns
274    ///
275    ///
276    /// ## `x_offset`
277    /// location to return x offset of a cell relative to @cell_area
278    ///
279    /// ## `y_offset`
280    /// location to return y offset of a cell relative to @cell_area
281    ///
282    /// ## `width`
283    /// location to return width needed to render a cell
284    ///
285    /// ## `height`
286    /// location to return height needed to render a cell
287    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
288    #[allow(deprecated)]
289    #[doc(alias = "gtk_tree_view_column_cell_get_size")]
290    pub fn cell_get_size(&self) -> (i32, i32, i32, i32) {
291        unsafe {
292            let mut x_offset = std::mem::MaybeUninit::uninit();
293            let mut y_offset = std::mem::MaybeUninit::uninit();
294            let mut width = std::mem::MaybeUninit::uninit();
295            let mut height = std::mem::MaybeUninit::uninit();
296            ffi::gtk_tree_view_column_cell_get_size(
297                self.to_glib_none().0,
298                x_offset.as_mut_ptr(),
299                y_offset.as_mut_ptr(),
300                width.as_mut_ptr(),
301                height.as_mut_ptr(),
302            );
303            (
304                x_offset.assume_init(),
305                y_offset.assume_init(),
306                width.assume_init(),
307                height.assume_init(),
308            )
309        }
310    }
311
312    /// Returns [`true`] if any of the cells packed into the @self are visible.
313    /// For this to be meaningful, you must first initialize the cells with
314    /// gtk_tree_view_column_cell_set_cell_data()
315    ///
316    /// # Deprecated since 4.10
317    ///
318    /// Use GtkColumnView instead
319    ///
320    /// # Returns
321    ///
322    /// [`true`], if any of the cells packed into the @self are currently visible
323    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
324    #[allow(deprecated)]
325    #[doc(alias = "gtk_tree_view_column_cell_is_visible")]
326    pub fn cell_is_visible(&self) -> bool {
327        unsafe {
328            from_glib(ffi::gtk_tree_view_column_cell_is_visible(
329                self.to_glib_none().0,
330            ))
331        }
332    }
333
334    /// Sets the cell renderer based on the @tree_model and @iter.  That is, for
335    /// every attribute mapping in @self, it will get a value from the set
336    /// column on the @iter, and use that value to set the attribute on the cell
337    /// renderer.  This is used primarily by the [`TreeView`][crate::TreeView].
338    ///
339    /// # Deprecated since 4.10
340    ///
341    /// Use GtkColumnView instead
342    /// ## `tree_model`
343    /// The [`TreeModel`][crate::TreeModel] to get the cell renderers attributes from.
344    /// ## `iter`
345    /// The [`TreeIter`][crate::TreeIter] to get the cell renderer’s attributes from.
346    /// ## `is_expander`
347    /// [`true`], if the row has children
348    /// ## `is_expanded`
349    /// [`true`], if the row has visible children
350    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
351    #[allow(deprecated)]
352    #[doc(alias = "gtk_tree_view_column_cell_set_cell_data")]
353    pub fn cell_set_cell_data(
354        &self,
355        tree_model: &impl IsA<TreeModel>,
356        iter: &TreeIter,
357        is_expander: bool,
358        is_expanded: bool,
359    ) {
360        unsafe {
361            ffi::gtk_tree_view_column_cell_set_cell_data(
362                self.to_glib_none().0,
363                tree_model.as_ref().to_glib_none().0,
364                mut_override(iter.to_glib_none().0),
365                is_expander.into_glib(),
366                is_expanded.into_glib(),
367            );
368        }
369    }
370
371    /// Unsets all the mappings on all renderers on the @self.
372    ///
373    /// # Deprecated since 4.10
374    ///
375    /// Use GtkColumnView instead
376    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
377    #[allow(deprecated)]
378    #[doc(alias = "gtk_tree_view_column_clear")]
379    pub fn clear(&self) {
380        unsafe {
381            ffi::gtk_tree_view_column_clear(self.to_glib_none().0);
382        }
383    }
384
385    /// Clears all existing attributes previously set with
386    /// gtk_tree_view_column_set_attributes().
387    ///
388    /// # Deprecated since 4.10
389    ///
390    /// Use GtkColumnView instead
391    /// ## `cell_renderer`
392    /// a [`CellRenderer`][crate::CellRenderer] to clear the attribute mapping on.
393    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
394    #[allow(deprecated)]
395    #[doc(alias = "gtk_tree_view_column_clear_attributes")]
396    pub fn clear_attributes(&self, cell_renderer: &impl IsA<CellRenderer>) {
397        unsafe {
398            ffi::gtk_tree_view_column_clear_attributes(
399                self.to_glib_none().0,
400                cell_renderer.as_ref().to_glib_none().0,
401            );
402        }
403    }
404
405    /// Emits the “clicked” signal on the column.  This function will only work if
406    /// @self is clickable.
407    ///
408    /// # Deprecated since 4.10
409    ///
410    /// Use GtkColumnView instead
411    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
412    #[allow(deprecated)]
413    #[doc(alias = "gtk_tree_view_column_clicked")]
414    pub fn clicked(&self) {
415        unsafe {
416            ffi::gtk_tree_view_column_clicked(self.to_glib_none().0);
417        }
418    }
419
420    /// Sets the current keyboard focus to be at @cell, if the column contains
421    /// 2 or more editable and activatable cells.
422    ///
423    /// # Deprecated since 4.10
424    ///
425    /// Use GtkColumnView instead
426    /// ## `cell`
427    /// A [`CellRenderer`][crate::CellRenderer]
428    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
429    #[allow(deprecated)]
430    #[doc(alias = "gtk_tree_view_column_focus_cell")]
431    pub fn focus_cell(&self, cell: &impl IsA<CellRenderer>) {
432        unsafe {
433            ffi::gtk_tree_view_column_focus_cell(
434                self.to_glib_none().0,
435                cell.as_ref().to_glib_none().0,
436            );
437        }
438    }
439
440    /// Returns the current x alignment of @self.  This value can range
441    /// between 0.0 and 1.0.
442    ///
443    /// # Deprecated since 4.10
444    ///
445    /// Use GtkColumnView instead
446    ///
447    /// # Returns
448    ///
449    /// The current alignent of @self.
450    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
451    #[allow(deprecated)]
452    #[doc(alias = "gtk_tree_view_column_get_alignment")]
453    #[doc(alias = "get_alignment")]
454    pub fn alignment(&self) -> f32 {
455        unsafe { ffi::gtk_tree_view_column_get_alignment(self.to_glib_none().0) }
456    }
457
458    /// Returns the button used in the treeview column header
459    ///
460    /// # Deprecated since 4.10
461    ///
462    /// Use GtkColumnView instead
463    ///
464    /// # Returns
465    ///
466    /// The button for the column header.
467    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
468    #[allow(deprecated)]
469    #[doc(alias = "gtk_tree_view_column_get_button")]
470    #[doc(alias = "get_button")]
471    pub fn button(&self) -> Widget {
472        unsafe { from_glib_none(ffi::gtk_tree_view_column_get_button(self.to_glib_none().0)) }
473    }
474
475    /// Returns [`true`] if the user can click on the header for the column.
476    ///
477    /// # Deprecated since 4.10
478    ///
479    /// Use GtkColumnView instead
480    ///
481    /// # Returns
482    ///
483    /// [`true`] if user can click the column header.
484    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
485    #[allow(deprecated)]
486    #[doc(alias = "gtk_tree_view_column_get_clickable")]
487    #[doc(alias = "get_clickable")]
488    #[doc(alias = "clickable")]
489    pub fn is_clickable(&self) -> bool {
490        unsafe {
491            from_glib(ffi::gtk_tree_view_column_get_clickable(
492                self.to_glib_none().0,
493            ))
494        }
495    }
496
497    /// Returns [`true`] if the column expands to fill available space.
498    ///
499    /// # Deprecated since 4.10
500    ///
501    /// Use GtkColumnView instead
502    ///
503    /// # Returns
504    ///
505    /// [`true`] if the column expands to fill available space.
506    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
507    #[allow(deprecated)]
508    #[doc(alias = "gtk_tree_view_column_get_expand")]
509    #[doc(alias = "get_expand")]
510    #[doc(alias = "expand")]
511    pub fn expands(&self) -> bool {
512        unsafe { from_glib(ffi::gtk_tree_view_column_get_expand(self.to_glib_none().0)) }
513    }
514
515    /// Gets the fixed width of the column.  This may not be the actual displayed
516    /// width of the column; for that, use gtk_tree_view_column_get_width().
517    ///
518    /// # Deprecated since 4.10
519    ///
520    /// Use GtkColumnView instead
521    ///
522    /// # Returns
523    ///
524    /// The fixed width of the column.
525    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
526    #[allow(deprecated)]
527    #[doc(alias = "gtk_tree_view_column_get_fixed_width")]
528    #[doc(alias = "get_fixed_width")]
529    #[doc(alias = "fixed-width")]
530    pub fn fixed_width(&self) -> i32 {
531        unsafe { ffi::gtk_tree_view_column_get_fixed_width(self.to_glib_none().0) }
532    }
533
534    /// Returns the maximum width in pixels of the @self, or -1 if no maximum
535    /// width is set.
536    ///
537    /// # Deprecated since 4.10
538    ///
539    /// Use GtkColumnView instead
540    ///
541    /// # Returns
542    ///
543    /// The maximum width of the @self.
544    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
545    #[allow(deprecated)]
546    #[doc(alias = "gtk_tree_view_column_get_max_width")]
547    #[doc(alias = "get_max_width")]
548    #[doc(alias = "max-width")]
549    pub fn max_width(&self) -> i32 {
550        unsafe { ffi::gtk_tree_view_column_get_max_width(self.to_glib_none().0) }
551    }
552
553    /// Returns the minimum width in pixels of the @self, or -1 if no minimum
554    /// width is set.
555    ///
556    /// # Deprecated since 4.10
557    ///
558    /// Use GtkColumnView instead
559    ///
560    /// # Returns
561    ///
562    /// The minimum width of the @self.
563    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
564    #[allow(deprecated)]
565    #[doc(alias = "gtk_tree_view_column_get_min_width")]
566    #[doc(alias = "get_min_width")]
567    #[doc(alias = "min-width")]
568    pub fn min_width(&self) -> i32 {
569        unsafe { ffi::gtk_tree_view_column_get_min_width(self.to_glib_none().0) }
570    }
571
572    /// Returns [`true`] if the @self can be reordered by the user.
573    ///
574    /// # Deprecated since 4.10
575    ///
576    /// Use GtkColumnView instead
577    ///
578    /// # Returns
579    ///
580    /// [`true`] if the @self can be reordered by the user.
581    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
582    #[allow(deprecated)]
583    #[doc(alias = "gtk_tree_view_column_get_reorderable")]
584    #[doc(alias = "get_reorderable")]
585    #[doc(alias = "reorderable")]
586    pub fn is_reorderable(&self) -> bool {
587        unsafe {
588            from_glib(ffi::gtk_tree_view_column_get_reorderable(
589                self.to_glib_none().0,
590            ))
591        }
592    }
593
594    /// Returns [`true`] if the @self can be resized by the end user.
595    ///
596    /// # Deprecated since 4.10
597    ///
598    /// Use GtkColumnView instead
599    ///
600    /// # Returns
601    ///
602    /// [`true`], if the @self can be resized.
603    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
604    #[allow(deprecated)]
605    #[doc(alias = "gtk_tree_view_column_get_resizable")]
606    #[doc(alias = "get_resizable")]
607    #[doc(alias = "resizable")]
608    pub fn is_resizable(&self) -> bool {
609        unsafe {
610            from_glib(ffi::gtk_tree_view_column_get_resizable(
611                self.to_glib_none().0,
612            ))
613        }
614    }
615
616    /// Returns the current type of @self.
617    ///
618    /// # Deprecated since 4.10
619    ///
620    /// Use GtkColumnView instead
621    ///
622    /// # Returns
623    ///
624    /// The type of @self.
625    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
626    #[allow(deprecated)]
627    #[doc(alias = "gtk_tree_view_column_get_sizing")]
628    #[doc(alias = "get_sizing")]
629    pub fn sizing(&self) -> TreeViewColumnSizing {
630        unsafe { from_glib(ffi::gtk_tree_view_column_get_sizing(self.to_glib_none().0)) }
631    }
632
633    /// Gets the logical @sort_column_id that the model sorts on
634    /// when this column is selected for sorting.
635    ///
636    /// See [`set_sort_column_id()`][Self::set_sort_column_id()].
637    ///
638    /// # Deprecated since 4.10
639    ///
640    /// Use GtkColumnView instead
641    ///
642    /// # Returns
643    ///
644    /// the current @sort_column_id for this column, or -1 if
645    ///   this column can’t be used for sorting
646    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
647    #[allow(deprecated)]
648    #[doc(alias = "gtk_tree_view_column_get_sort_column_id")]
649    #[doc(alias = "get_sort_column_id")]
650    #[doc(alias = "sort-column-id")]
651    pub fn sort_column_id(&self) -> i32 {
652        unsafe { ffi::gtk_tree_view_column_get_sort_column_id(self.to_glib_none().0) }
653    }
654
655    /// Gets the value set by gtk_tree_view_column_set_sort_indicator().
656    ///
657    /// # Deprecated since 4.10
658    ///
659    /// Use GtkColumnView instead
660    ///
661    /// # Returns
662    ///
663    /// whether the sort indicator arrow is displayed
664    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
665    #[allow(deprecated)]
666    #[doc(alias = "gtk_tree_view_column_get_sort_indicator")]
667    #[doc(alias = "get_sort_indicator")]
668    #[doc(alias = "sort-indicator")]
669    pub fn is_sort_indicator(&self) -> bool {
670        unsafe {
671            from_glib(ffi::gtk_tree_view_column_get_sort_indicator(
672                self.to_glib_none().0,
673            ))
674        }
675    }
676
677    /// Gets the value set by gtk_tree_view_column_set_sort_order().
678    ///
679    /// # Deprecated since 4.10
680    ///
681    /// Use GtkColumnView instead
682    ///
683    /// # Returns
684    ///
685    /// the sort order the sort indicator is indicating
686    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
687    #[allow(deprecated)]
688    #[doc(alias = "gtk_tree_view_column_get_sort_order")]
689    #[doc(alias = "get_sort_order")]
690    #[doc(alias = "sort-order")]
691    pub fn sort_order(&self) -> SortType {
692        unsafe {
693            from_glib(ffi::gtk_tree_view_column_get_sort_order(
694                self.to_glib_none().0,
695            ))
696        }
697    }
698
699    /// Returns the spacing of @self.
700    ///
701    /// # Deprecated since 4.10
702    ///
703    /// Use GtkColumnView instead
704    ///
705    /// # Returns
706    ///
707    /// the spacing of @self.
708    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
709    #[allow(deprecated)]
710    #[doc(alias = "gtk_tree_view_column_get_spacing")]
711    #[doc(alias = "get_spacing")]
712    pub fn spacing(&self) -> i32 {
713        unsafe { ffi::gtk_tree_view_column_get_spacing(self.to_glib_none().0) }
714    }
715
716    /// Returns the title of the widget.
717    ///
718    /// # Deprecated since 4.10
719    ///
720    /// Use GtkColumnView instead
721    ///
722    /// # Returns
723    ///
724    /// the title of the column. This string should not be
725    /// modified or freed.
726    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
727    #[allow(deprecated)]
728    #[doc(alias = "gtk_tree_view_column_get_title")]
729    #[doc(alias = "get_title")]
730    pub fn title(&self) -> glib::GString {
731        unsafe { from_glib_none(ffi::gtk_tree_view_column_get_title(self.to_glib_none().0)) }
732    }
733
734    /// Returns the [`TreeView`][crate::TreeView] wherein @self has been inserted.
735    /// If @column is currently not inserted in any tree view, [`None`] is
736    /// returned.
737    ///
738    /// # Deprecated since 4.10
739    ///
740    /// Use GtkColumnView instead
741    ///
742    /// # Returns
743    ///
744    /// The tree view wherein @column
745    ///   has been inserted
746    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
747    #[allow(deprecated)]
748    #[doc(alias = "gtk_tree_view_column_get_tree_view")]
749    #[doc(alias = "get_tree_view")]
750    pub fn tree_view(&self) -> Option<Widget> {
751        unsafe {
752            from_glib_none(ffi::gtk_tree_view_column_get_tree_view(
753                self.to_glib_none().0,
754            ))
755        }
756    }
757
758    /// Returns [`true`] if @self is visible.
759    ///
760    /// # Deprecated since 4.10
761    ///
762    /// Use GtkColumnView instead
763    ///
764    /// # Returns
765    ///
766    /// whether the column is visible or not.  If it is visible, then
767    /// the tree will show the column.
768    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
769    #[allow(deprecated)]
770    #[doc(alias = "gtk_tree_view_column_get_visible")]
771    #[doc(alias = "get_visible")]
772    #[doc(alias = "visible")]
773    pub fn is_visible(&self) -> bool {
774        unsafe { from_glib(ffi::gtk_tree_view_column_get_visible(self.to_glib_none().0)) }
775    }
776
777    /// Returns the [`Widget`][crate::Widget] in the button on the column header.
778    ///
779    /// If a custom widget has not been set then [`None`] is returned.
780    ///
781    /// # Deprecated since 4.10
782    ///
783    /// Use GtkColumnView instead
784    ///
785    /// # Returns
786    ///
787    /// The [`Widget`][crate::Widget] in the column header
788    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
789    #[allow(deprecated)]
790    #[doc(alias = "gtk_tree_view_column_get_widget")]
791    #[doc(alias = "get_widget")]
792    pub fn widget(&self) -> Option<Widget> {
793        unsafe { from_glib_none(ffi::gtk_tree_view_column_get_widget(self.to_glib_none().0)) }
794    }
795
796    /// Returns the current size of @self in pixels.
797    ///
798    /// # Deprecated since 4.10
799    ///
800    /// Use GtkColumnView instead
801    ///
802    /// # Returns
803    ///
804    /// The current width of @self.
805    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
806    #[allow(deprecated)]
807    #[doc(alias = "gtk_tree_view_column_get_width")]
808    #[doc(alias = "get_width")]
809    pub fn width(&self) -> i32 {
810        unsafe { ffi::gtk_tree_view_column_get_width(self.to_glib_none().0) }
811    }
812
813    /// Returns the current X offset of @self in pixels.
814    ///
815    /// # Deprecated since 4.10
816    ///
817    /// Use GtkColumnView instead
818    ///
819    /// # Returns
820    ///
821    /// The current X offset of @self.
822    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
823    #[allow(deprecated)]
824    #[doc(alias = "gtk_tree_view_column_get_x_offset")]
825    #[doc(alias = "get_x_offset")]
826    #[doc(alias = "x-offset")]
827    pub fn x_offset(&self) -> i32 {
828        unsafe { ffi::gtk_tree_view_column_get_x_offset(self.to_glib_none().0) }
829    }
830
831    /// Adds the @cell to end of the column. If @expand is [`false`], then the @cell
832    /// is allocated no more space than it needs. Any unused space is divided
833    /// evenly between cells for which @expand is [`true`].
834    ///
835    /// # Deprecated since 4.10
836    ///
837    /// Use GtkColumnView instead
838    /// ## `cell`
839    /// The [`CellRenderer`][crate::CellRenderer]
840    /// ## `expand`
841    /// [`true`] if @cell is to be given extra space allocated to @self.
842    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
843    #[allow(deprecated)]
844    #[doc(alias = "gtk_tree_view_column_pack_end")]
845    pub fn pack_end(&self, cell: &impl IsA<CellRenderer>, expand: bool) {
846        unsafe {
847            ffi::gtk_tree_view_column_pack_end(
848                self.to_glib_none().0,
849                cell.as_ref().to_glib_none().0,
850                expand.into_glib(),
851            );
852        }
853    }
854
855    /// Packs the @cell into the beginning of the column. If @expand is [`false`], then
856    /// the @cell is allocated no more space than it needs. Any unused space is divided
857    /// evenly between cells for which @expand is [`true`].
858    ///
859    /// # Deprecated since 4.10
860    ///
861    /// Use GtkColumnView instead
862    /// ## `cell`
863    /// The [`CellRenderer`][crate::CellRenderer]
864    /// ## `expand`
865    /// [`true`] if @cell is to be given extra space allocated to @self.
866    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
867    #[allow(deprecated)]
868    #[doc(alias = "gtk_tree_view_column_pack_start")]
869    pub fn pack_start(&self, cell: &impl IsA<CellRenderer>, expand: bool) {
870        unsafe {
871            ffi::gtk_tree_view_column_pack_start(
872                self.to_glib_none().0,
873                cell.as_ref().to_glib_none().0,
874                expand.into_glib(),
875            );
876        }
877    }
878
879    /// Flags the column, and the cell renderers added to this column, to have
880    /// their sizes renegotiated.
881    ///
882    /// # Deprecated since 4.10
883    ///
884    /// Use GtkColumnView instead
885    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
886    #[allow(deprecated)]
887    #[doc(alias = "gtk_tree_view_column_queue_resize")]
888    pub fn queue_resize(&self) {
889        unsafe {
890            ffi::gtk_tree_view_column_queue_resize(self.to_glib_none().0);
891        }
892    }
893
894    /// Sets the alignment of the title or custom widget inside the column header.
895    /// The alignment determines its location inside the button -- 0.0 for left, 0.5
896    /// for center, 1.0 for right.
897    ///
898    /// # Deprecated since 4.10
899    ///
900    /// Use GtkColumnView instead
901    /// ## `xalign`
902    /// The alignment, which is between [0.0 and 1.0] inclusive.
903    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
904    #[allow(deprecated)]
905    #[doc(alias = "gtk_tree_view_column_set_alignment")]
906    #[doc(alias = "alignment")]
907    pub fn set_alignment(&self, xalign: f32) {
908        unsafe {
909            ffi::gtk_tree_view_column_set_alignment(self.to_glib_none().0, xalign);
910        }
911    }
912
913    /// Sets the `GtkTreeCellDataFunc` to use for the column.
914    ///
915    /// This
916    /// function is used instead of the standard attributes mapping for
917    /// setting the column value, and should set the value of @self's
918    /// cell renderer as appropriate.  @func may be [`None`] to remove an
919    /// older one.
920    ///
921    /// # Deprecated since 4.10
922    ///
923    /// Use GtkColumnView instead
924    /// ## `cell_renderer`
925    /// A [`CellRenderer`][crate::CellRenderer]
926    /// ## `func`
927    /// The `GtkTreeCellDataFunc` to use.
928    /// ## `func_data`
929    /// The user data for @func.
930    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
931    #[allow(deprecated)]
932    #[doc(alias = "gtk_tree_view_column_set_cell_data_func")]
933    pub fn set_cell_data_func<
934        P: Fn(&TreeViewColumn, &CellRenderer, &TreeModel, &TreeIter) + 'static,
935    >(
936        &self,
937        cell_renderer: &impl IsA<CellRenderer>,
938        func: P,
939    ) {
940        let func_data: Box_<P> = Box_::new(func);
941        unsafe extern "C" fn func_func<
942            P: Fn(&TreeViewColumn, &CellRenderer, &TreeModel, &TreeIter) + 'static,
943        >(
944            tree_column: *mut ffi::GtkTreeViewColumn,
945            cell: *mut ffi::GtkCellRenderer,
946            tree_model: *mut ffi::GtkTreeModel,
947            iter: *mut ffi::GtkTreeIter,
948            data: glib::ffi::gpointer,
949        ) {
950            let tree_column = from_glib_borrow(tree_column);
951            let cell = from_glib_borrow(cell);
952            let tree_model = from_glib_borrow(tree_model);
953            let iter = from_glib_borrow(iter);
954            let callback = &*(data as *mut P);
955            (*callback)(&tree_column, &cell, &tree_model, &iter)
956        }
957        let func = Some(func_func::<P> as _);
958        unsafe extern "C" fn destroy_func<
959            P: Fn(&TreeViewColumn, &CellRenderer, &TreeModel, &TreeIter) + 'static,
960        >(
961            data: glib::ffi::gpointer,
962        ) {
963            let _callback = Box_::from_raw(data as *mut P);
964        }
965        let destroy_call4 = Some(destroy_func::<P> as _);
966        let super_callback0: Box_<P> = func_data;
967        unsafe {
968            ffi::gtk_tree_view_column_set_cell_data_func(
969                self.to_glib_none().0,
970                cell_renderer.as_ref().to_glib_none().0,
971                func,
972                Box_::into_raw(super_callback0) as *mut _,
973                destroy_call4,
974            );
975        }
976    }
977
978    /// Sets the header to be active if @clickable is [`true`].  When the header is
979    /// active, then it can take keyboard focus, and can be clicked.
980    ///
981    /// # Deprecated since 4.10
982    ///
983    /// Use GtkColumnView instead
984    /// ## `clickable`
985    /// [`true`] if the header is active.
986    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
987    #[allow(deprecated)]
988    #[doc(alias = "gtk_tree_view_column_set_clickable")]
989    #[doc(alias = "clickable")]
990    pub fn set_clickable(&self, clickable: bool) {
991        unsafe {
992            ffi::gtk_tree_view_column_set_clickable(self.to_glib_none().0, clickable.into_glib());
993        }
994    }
995
996    /// Sets the column to take available extra space.  This space is shared equally
997    /// amongst all columns that have the expand set to [`true`].  If no column has this
998    /// option set, then the last column gets all extra space.  By default, every
999    /// column is created with this [`false`].
1000    ///
1001    /// Along with “fixed-width”, the “expand” property changes when the column is
1002    /// resized by the user.
1003    ///
1004    /// # Deprecated since 4.10
1005    ///
1006    /// Use GtkColumnView instead
1007    /// ## `expand`
1008    /// [`true`] if the column should expand to fill available space.
1009    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1010    #[allow(deprecated)]
1011    #[doc(alias = "gtk_tree_view_column_set_expand")]
1012    #[doc(alias = "expand")]
1013    pub fn set_expand(&self, expand: bool) {
1014        unsafe {
1015            ffi::gtk_tree_view_column_set_expand(self.to_glib_none().0, expand.into_glib());
1016        }
1017    }
1018
1019    /// If @fixed_width is not -1, sets the fixed width of @self; otherwise
1020    /// unsets it.  The effective value of @fixed_width is clamped between the
1021    /// minimum and maximum width of the column; however, the value stored in the
1022    /// “fixed-width” property is not clamped.  If the column sizing is
1023    /// [`TreeViewColumnSizing::GrowOnly`][crate::TreeViewColumnSizing::GrowOnly] or [`TreeViewColumnSizing::Autosize`][crate::TreeViewColumnSizing::Autosize], setting
1024    /// a fixed width overrides the automatically calculated width.  Note that
1025    /// @fixed_width is only a hint to GTK; the width actually allocated to the
1026    /// column may be greater or less than requested.
1027    ///
1028    /// Along with “expand”, the “fixed-width” property changes when the column is
1029    /// resized by the user.
1030    ///
1031    /// # Deprecated since 4.10
1032    ///
1033    /// Use GtkColumnView instead
1034    /// ## `fixed_width`
1035    /// The new fixed width, in pixels, or -1.
1036    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1037    #[allow(deprecated)]
1038    #[doc(alias = "gtk_tree_view_column_set_fixed_width")]
1039    #[doc(alias = "fixed-width")]
1040    pub fn set_fixed_width(&self, fixed_width: i32) {
1041        unsafe {
1042            ffi::gtk_tree_view_column_set_fixed_width(self.to_glib_none().0, fixed_width);
1043        }
1044    }
1045
1046    /// Sets the maximum width of the @self.  If @max_width is -1, then the
1047    /// maximum width is unset.  Note, the column can actually be wider than max
1048    /// width if it’s the last column in a view.  In this case, the column expands to
1049    /// fill any extra space.
1050    ///
1051    /// # Deprecated since 4.10
1052    ///
1053    /// Use GtkColumnView instead
1054    /// ## `max_width`
1055    /// The maximum width of the column in pixels, or -1.
1056    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1057    #[allow(deprecated)]
1058    #[doc(alias = "gtk_tree_view_column_set_max_width")]
1059    #[doc(alias = "max-width")]
1060    pub fn set_max_width(&self, max_width: i32) {
1061        unsafe {
1062            ffi::gtk_tree_view_column_set_max_width(self.to_glib_none().0, max_width);
1063        }
1064    }
1065
1066    /// Sets the minimum width of the @self.  If @min_width is -1, then the
1067    /// minimum width is unset.
1068    ///
1069    /// # Deprecated since 4.10
1070    ///
1071    /// Use GtkColumnView instead
1072    /// ## `min_width`
1073    /// The minimum width of the column in pixels, or -1.
1074    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1075    #[allow(deprecated)]
1076    #[doc(alias = "gtk_tree_view_column_set_min_width")]
1077    #[doc(alias = "min-width")]
1078    pub fn set_min_width(&self, min_width: i32) {
1079        unsafe {
1080            ffi::gtk_tree_view_column_set_min_width(self.to_glib_none().0, min_width);
1081        }
1082    }
1083
1084    /// If @reorderable is [`true`], then the column can be reordered by the end user
1085    /// dragging the header.
1086    ///
1087    /// # Deprecated since 4.10
1088    ///
1089    /// Use GtkColumnView instead
1090    /// ## `reorderable`
1091    /// [`true`], if the column can be reordered.
1092    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1093    #[allow(deprecated)]
1094    #[doc(alias = "gtk_tree_view_column_set_reorderable")]
1095    #[doc(alias = "reorderable")]
1096    pub fn set_reorderable(&self, reorderable: bool) {
1097        unsafe {
1098            ffi::gtk_tree_view_column_set_reorderable(
1099                self.to_glib_none().0,
1100                reorderable.into_glib(),
1101            );
1102        }
1103    }
1104
1105    /// If @resizable is [`true`], then the user can explicitly resize the column by
1106    /// grabbing the outer edge of the column button.
1107    ///
1108    /// If resizable is [`true`] and
1109    /// sizing mode of the column is [`TreeViewColumnSizing::Autosize`][crate::TreeViewColumnSizing::Autosize], then the sizing
1110    /// mode is changed to [`TreeViewColumnSizing::GrowOnly`][crate::TreeViewColumnSizing::GrowOnly].
1111    ///
1112    /// # Deprecated since 4.10
1113    ///
1114    /// Use GtkColumnView instead
1115    /// ## `resizable`
1116    /// [`true`], if the column can be resized
1117    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1118    #[allow(deprecated)]
1119    #[doc(alias = "gtk_tree_view_column_set_resizable")]
1120    #[doc(alias = "resizable")]
1121    pub fn set_resizable(&self, resizable: bool) {
1122        unsafe {
1123            ffi::gtk_tree_view_column_set_resizable(self.to_glib_none().0, resizable.into_glib());
1124        }
1125    }
1126
1127    /// Sets the growth behavior of @self to @type_.
1128    ///
1129    /// # Deprecated since 4.10
1130    ///
1131    /// Use GtkColumnView instead
1132    /// ## `type_`
1133    /// The [`TreeViewColumn`][crate::TreeViewColumn]Sizing.
1134    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1135    #[allow(deprecated)]
1136    #[doc(alias = "gtk_tree_view_column_set_sizing")]
1137    #[doc(alias = "sizing")]
1138    pub fn set_sizing(&self, type_: TreeViewColumnSizing) {
1139        unsafe {
1140            ffi::gtk_tree_view_column_set_sizing(self.to_glib_none().0, type_.into_glib());
1141        }
1142    }
1143
1144    /// Sets the logical @sort_column_id that this column sorts on when this column
1145    /// is selected for sorting.  Doing so makes the column header clickable.
1146    ///
1147    /// # Deprecated since 4.10
1148    ///
1149    /// Use GtkColumnView instead
1150    /// ## `sort_column_id`
1151    /// The @sort_column_id of the model to sort on.
1152    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1153    #[allow(deprecated)]
1154    #[doc(alias = "gtk_tree_view_column_set_sort_column_id")]
1155    #[doc(alias = "sort-column-id")]
1156    pub fn set_sort_column_id(&self, sort_column_id: i32) {
1157        unsafe {
1158            ffi::gtk_tree_view_column_set_sort_column_id(self.to_glib_none().0, sort_column_id);
1159        }
1160    }
1161
1162    /// Call this function with a @setting of [`true`] to display an arrow in
1163    /// the header button indicating the column is sorted. Call
1164    /// gtk_tree_view_column_set_sort_order() to change the direction of
1165    /// the arrow.
1166    ///
1167    /// # Deprecated since 4.10
1168    ///
1169    /// Use GtkColumnView instead
1170    /// ## `setting`
1171    /// [`true`] to display an indicator that the column is sorted
1172    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1173    #[allow(deprecated)]
1174    #[doc(alias = "gtk_tree_view_column_set_sort_indicator")]
1175    #[doc(alias = "sort-indicator")]
1176    pub fn set_sort_indicator(&self, setting: bool) {
1177        unsafe {
1178            ffi::gtk_tree_view_column_set_sort_indicator(
1179                self.to_glib_none().0,
1180                setting.into_glib(),
1181            );
1182        }
1183    }
1184
1185    /// Changes the appearance of the sort indicator.
1186    ///
1187    /// This does not actually sort the model.  Use
1188    /// gtk_tree_view_column_set_sort_column_id() if you want automatic sorting
1189    /// support.  This function is primarily for custom sorting behavior, and should
1190    /// be used in conjunction with gtk_tree_sortable_set_sort_column_id() to do
1191    /// that. For custom models, the mechanism will vary.
1192    ///
1193    /// The sort indicator changes direction to indicate normal sort or reverse sort.
1194    /// Note that you must have the sort indicator enabled to see anything when
1195    /// calling this function; see gtk_tree_view_column_set_sort_indicator().
1196    ///
1197    /// # Deprecated since 4.10
1198    ///
1199    /// Use GtkColumnView instead
1200    /// ## `order`
1201    /// sort order that the sort indicator should indicate
1202    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1203    #[allow(deprecated)]
1204    #[doc(alias = "gtk_tree_view_column_set_sort_order")]
1205    #[doc(alias = "sort-order")]
1206    pub fn set_sort_order(&self, order: SortType) {
1207        unsafe {
1208            ffi::gtk_tree_view_column_set_sort_order(self.to_glib_none().0, order.into_glib());
1209        }
1210    }
1211
1212    /// Sets the spacing field of @self, which is the number of pixels to
1213    /// place between cell renderers packed into it.
1214    ///
1215    /// # Deprecated since 4.10
1216    ///
1217    /// Use GtkColumnView instead
1218    /// ## `spacing`
1219    /// distance between cell renderers in pixels.
1220    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1221    #[allow(deprecated)]
1222    #[doc(alias = "gtk_tree_view_column_set_spacing")]
1223    #[doc(alias = "spacing")]
1224    pub fn set_spacing(&self, spacing: i32) {
1225        unsafe {
1226            ffi::gtk_tree_view_column_set_spacing(self.to_glib_none().0, spacing);
1227        }
1228    }
1229
1230    /// Sets the title of the @self.  If a custom widget has been set, then
1231    /// this value is ignored.
1232    ///
1233    /// # Deprecated since 4.10
1234    ///
1235    /// Use GtkColumnView instead
1236    /// ## `title`
1237    /// The title of the @self.
1238    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1239    #[allow(deprecated)]
1240    #[doc(alias = "gtk_tree_view_column_set_title")]
1241    #[doc(alias = "title")]
1242    pub fn set_title(&self, title: &str) {
1243        unsafe {
1244            ffi::gtk_tree_view_column_set_title(self.to_glib_none().0, title.to_glib_none().0);
1245        }
1246    }
1247
1248    /// Sets the visibility of @self.
1249    ///
1250    /// # Deprecated since 4.10
1251    ///
1252    /// Use GtkColumnView instead
1253    /// ## `visible`
1254    /// [`true`] if the @self is visible.
1255    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1256    #[allow(deprecated)]
1257    #[doc(alias = "gtk_tree_view_column_set_visible")]
1258    #[doc(alias = "visible")]
1259    pub fn set_visible(&self, visible: bool) {
1260        unsafe {
1261            ffi::gtk_tree_view_column_set_visible(self.to_glib_none().0, visible.into_glib());
1262        }
1263    }
1264
1265    /// Sets the widget in the header to be @widget.  If widget is [`None`], then the
1266    /// header button is set with a [`Label`][crate::Label] set to the title of @self.
1267    ///
1268    /// # Deprecated since 4.10
1269    ///
1270    /// Use GtkColumnView instead
1271    /// ## `widget`
1272    /// A child [`Widget`][crate::Widget]
1273    #[cfg_attr(feature = "v4_10", deprecated = "Since 4.10")]
1274    #[allow(deprecated)]
1275    #[doc(alias = "gtk_tree_view_column_set_widget")]
1276    #[doc(alias = "widget")]
1277    pub fn set_widget(&self, widget: Option<&impl IsA<Widget>>) {
1278        unsafe {
1279            ffi::gtk_tree_view_column_set_widget(
1280                self.to_glib_none().0,
1281                widget.map(|p| p.as_ref()).to_glib_none().0,
1282            );
1283        }
1284    }
1285
1286    /// The [`CellArea`][crate::CellArea] used to layout cell renderers for this column.
1287    ///
1288    /// If no area is specified when creating the tree view column with gtk_tree_view_column_new_with_area()
1289    /// a horizontally oriented [`CellAreaBox`][crate::CellAreaBox] will be used.
1290    #[doc(alias = "cell-area")]
1291    pub fn cell_area(&self) -> Option<CellArea> {
1292        ObjectExt::property(self, "cell-area")
1293    }
1294
1295    /// Emitted when the column's header has been clicked.
1296    #[doc(alias = "clicked")]
1297    pub fn connect_clicked<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1298        unsafe extern "C" fn clicked_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1299            this: *mut ffi::GtkTreeViewColumn,
1300            f: glib::ffi::gpointer,
1301        ) {
1302            let f: &F = &*(f as *const F);
1303            f(&from_glib_borrow(this))
1304        }
1305        unsafe {
1306            let f: Box_<F> = Box_::new(f);
1307            connect_raw(
1308                self.as_ptr() as *mut _,
1309                b"clicked\0".as_ptr() as *const _,
1310                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1311                    clicked_trampoline::<F> as *const (),
1312                )),
1313                Box_::into_raw(f),
1314            )
1315        }
1316    }
1317
1318    #[doc(alias = "alignment")]
1319    pub fn connect_alignment_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1320        unsafe extern "C" fn notify_alignment_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1321            this: *mut ffi::GtkTreeViewColumn,
1322            _param_spec: glib::ffi::gpointer,
1323            f: glib::ffi::gpointer,
1324        ) {
1325            let f: &F = &*(f as *const F);
1326            f(&from_glib_borrow(this))
1327        }
1328        unsafe {
1329            let f: Box_<F> = Box_::new(f);
1330            connect_raw(
1331                self.as_ptr() as *mut _,
1332                b"notify::alignment\0".as_ptr() as *const _,
1333                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1334                    notify_alignment_trampoline::<F> as *const (),
1335                )),
1336                Box_::into_raw(f),
1337            )
1338        }
1339    }
1340
1341    #[doc(alias = "clickable")]
1342    pub fn connect_clickable_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1343        unsafe extern "C" fn notify_clickable_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1344            this: *mut ffi::GtkTreeViewColumn,
1345            _param_spec: glib::ffi::gpointer,
1346            f: glib::ffi::gpointer,
1347        ) {
1348            let f: &F = &*(f as *const F);
1349            f(&from_glib_borrow(this))
1350        }
1351        unsafe {
1352            let f: Box_<F> = Box_::new(f);
1353            connect_raw(
1354                self.as_ptr() as *mut _,
1355                b"notify::clickable\0".as_ptr() as *const _,
1356                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1357                    notify_clickable_trampoline::<F> as *const (),
1358                )),
1359                Box_::into_raw(f),
1360            )
1361        }
1362    }
1363
1364    #[doc(alias = "expand")]
1365    pub fn connect_expand_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1366        unsafe extern "C" fn notify_expand_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1367            this: *mut ffi::GtkTreeViewColumn,
1368            _param_spec: glib::ffi::gpointer,
1369            f: glib::ffi::gpointer,
1370        ) {
1371            let f: &F = &*(f as *const F);
1372            f(&from_glib_borrow(this))
1373        }
1374        unsafe {
1375            let f: Box_<F> = Box_::new(f);
1376            connect_raw(
1377                self.as_ptr() as *mut _,
1378                b"notify::expand\0".as_ptr() as *const _,
1379                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1380                    notify_expand_trampoline::<F> as *const (),
1381                )),
1382                Box_::into_raw(f),
1383            )
1384        }
1385    }
1386
1387    #[doc(alias = "fixed-width")]
1388    pub fn connect_fixed_width_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1389        unsafe extern "C" fn notify_fixed_width_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1390            this: *mut ffi::GtkTreeViewColumn,
1391            _param_spec: glib::ffi::gpointer,
1392            f: glib::ffi::gpointer,
1393        ) {
1394            let f: &F = &*(f as *const F);
1395            f(&from_glib_borrow(this))
1396        }
1397        unsafe {
1398            let f: Box_<F> = Box_::new(f);
1399            connect_raw(
1400                self.as_ptr() as *mut _,
1401                b"notify::fixed-width\0".as_ptr() as *const _,
1402                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1403                    notify_fixed_width_trampoline::<F> as *const (),
1404                )),
1405                Box_::into_raw(f),
1406            )
1407        }
1408    }
1409
1410    #[doc(alias = "max-width")]
1411    pub fn connect_max_width_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1412        unsafe extern "C" fn notify_max_width_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1413            this: *mut ffi::GtkTreeViewColumn,
1414            _param_spec: glib::ffi::gpointer,
1415            f: glib::ffi::gpointer,
1416        ) {
1417            let f: &F = &*(f as *const F);
1418            f(&from_glib_borrow(this))
1419        }
1420        unsafe {
1421            let f: Box_<F> = Box_::new(f);
1422            connect_raw(
1423                self.as_ptr() as *mut _,
1424                b"notify::max-width\0".as_ptr() as *const _,
1425                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1426                    notify_max_width_trampoline::<F> as *const (),
1427                )),
1428                Box_::into_raw(f),
1429            )
1430        }
1431    }
1432
1433    #[doc(alias = "min-width")]
1434    pub fn connect_min_width_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1435        unsafe extern "C" fn notify_min_width_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1436            this: *mut ffi::GtkTreeViewColumn,
1437            _param_spec: glib::ffi::gpointer,
1438            f: glib::ffi::gpointer,
1439        ) {
1440            let f: &F = &*(f as *const F);
1441            f(&from_glib_borrow(this))
1442        }
1443        unsafe {
1444            let f: Box_<F> = Box_::new(f);
1445            connect_raw(
1446                self.as_ptr() as *mut _,
1447                b"notify::min-width\0".as_ptr() as *const _,
1448                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1449                    notify_min_width_trampoline::<F> as *const (),
1450                )),
1451                Box_::into_raw(f),
1452            )
1453        }
1454    }
1455
1456    #[doc(alias = "reorderable")]
1457    pub fn connect_reorderable_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1458        unsafe extern "C" fn notify_reorderable_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1459            this: *mut ffi::GtkTreeViewColumn,
1460            _param_spec: glib::ffi::gpointer,
1461            f: glib::ffi::gpointer,
1462        ) {
1463            let f: &F = &*(f as *const F);
1464            f(&from_glib_borrow(this))
1465        }
1466        unsafe {
1467            let f: Box_<F> = Box_::new(f);
1468            connect_raw(
1469                self.as_ptr() as *mut _,
1470                b"notify::reorderable\0".as_ptr() as *const _,
1471                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1472                    notify_reorderable_trampoline::<F> as *const (),
1473                )),
1474                Box_::into_raw(f),
1475            )
1476        }
1477    }
1478
1479    #[doc(alias = "resizable")]
1480    pub fn connect_resizable_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1481        unsafe extern "C" fn notify_resizable_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1482            this: *mut ffi::GtkTreeViewColumn,
1483            _param_spec: glib::ffi::gpointer,
1484            f: glib::ffi::gpointer,
1485        ) {
1486            let f: &F = &*(f as *const F);
1487            f(&from_glib_borrow(this))
1488        }
1489        unsafe {
1490            let f: Box_<F> = Box_::new(f);
1491            connect_raw(
1492                self.as_ptr() as *mut _,
1493                b"notify::resizable\0".as_ptr() as *const _,
1494                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1495                    notify_resizable_trampoline::<F> as *const (),
1496                )),
1497                Box_::into_raw(f),
1498            )
1499        }
1500    }
1501
1502    #[doc(alias = "sizing")]
1503    pub fn connect_sizing_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1504        unsafe extern "C" fn notify_sizing_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1505            this: *mut ffi::GtkTreeViewColumn,
1506            _param_spec: glib::ffi::gpointer,
1507            f: glib::ffi::gpointer,
1508        ) {
1509            let f: &F = &*(f as *const F);
1510            f(&from_glib_borrow(this))
1511        }
1512        unsafe {
1513            let f: Box_<F> = Box_::new(f);
1514            connect_raw(
1515                self.as_ptr() as *mut _,
1516                b"notify::sizing\0".as_ptr() as *const _,
1517                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1518                    notify_sizing_trampoline::<F> as *const (),
1519                )),
1520                Box_::into_raw(f),
1521            )
1522        }
1523    }
1524
1525    #[doc(alias = "sort-column-id")]
1526    pub fn connect_sort_column_id_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1527        unsafe extern "C" fn notify_sort_column_id_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1528            this: *mut ffi::GtkTreeViewColumn,
1529            _param_spec: glib::ffi::gpointer,
1530            f: glib::ffi::gpointer,
1531        ) {
1532            let f: &F = &*(f as *const F);
1533            f(&from_glib_borrow(this))
1534        }
1535        unsafe {
1536            let f: Box_<F> = Box_::new(f);
1537            connect_raw(
1538                self.as_ptr() as *mut _,
1539                b"notify::sort-column-id\0".as_ptr() as *const _,
1540                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1541                    notify_sort_column_id_trampoline::<F> as *const (),
1542                )),
1543                Box_::into_raw(f),
1544            )
1545        }
1546    }
1547
1548    #[doc(alias = "sort-indicator")]
1549    pub fn connect_sort_indicator_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1550        unsafe extern "C" fn notify_sort_indicator_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1551            this: *mut ffi::GtkTreeViewColumn,
1552            _param_spec: glib::ffi::gpointer,
1553            f: glib::ffi::gpointer,
1554        ) {
1555            let f: &F = &*(f as *const F);
1556            f(&from_glib_borrow(this))
1557        }
1558        unsafe {
1559            let f: Box_<F> = Box_::new(f);
1560            connect_raw(
1561                self.as_ptr() as *mut _,
1562                b"notify::sort-indicator\0".as_ptr() as *const _,
1563                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1564                    notify_sort_indicator_trampoline::<F> as *const (),
1565                )),
1566                Box_::into_raw(f),
1567            )
1568        }
1569    }
1570
1571    #[doc(alias = "sort-order")]
1572    pub fn connect_sort_order_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1573        unsafe extern "C" fn notify_sort_order_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1574            this: *mut ffi::GtkTreeViewColumn,
1575            _param_spec: glib::ffi::gpointer,
1576            f: glib::ffi::gpointer,
1577        ) {
1578            let f: &F = &*(f as *const F);
1579            f(&from_glib_borrow(this))
1580        }
1581        unsafe {
1582            let f: Box_<F> = Box_::new(f);
1583            connect_raw(
1584                self.as_ptr() as *mut _,
1585                b"notify::sort-order\0".as_ptr() as *const _,
1586                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1587                    notify_sort_order_trampoline::<F> as *const (),
1588                )),
1589                Box_::into_raw(f),
1590            )
1591        }
1592    }
1593
1594    #[doc(alias = "spacing")]
1595    pub fn connect_spacing_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1596        unsafe extern "C" fn notify_spacing_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1597            this: *mut ffi::GtkTreeViewColumn,
1598            _param_spec: glib::ffi::gpointer,
1599            f: glib::ffi::gpointer,
1600        ) {
1601            let f: &F = &*(f as *const F);
1602            f(&from_glib_borrow(this))
1603        }
1604        unsafe {
1605            let f: Box_<F> = Box_::new(f);
1606            connect_raw(
1607                self.as_ptr() as *mut _,
1608                b"notify::spacing\0".as_ptr() as *const _,
1609                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1610                    notify_spacing_trampoline::<F> as *const (),
1611                )),
1612                Box_::into_raw(f),
1613            )
1614        }
1615    }
1616
1617    #[doc(alias = "title")]
1618    pub fn connect_title_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1619        unsafe extern "C" fn notify_title_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1620            this: *mut ffi::GtkTreeViewColumn,
1621            _param_spec: glib::ffi::gpointer,
1622            f: glib::ffi::gpointer,
1623        ) {
1624            let f: &F = &*(f as *const F);
1625            f(&from_glib_borrow(this))
1626        }
1627        unsafe {
1628            let f: Box_<F> = Box_::new(f);
1629            connect_raw(
1630                self.as_ptr() as *mut _,
1631                b"notify::title\0".as_ptr() as *const _,
1632                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1633                    notify_title_trampoline::<F> as *const (),
1634                )),
1635                Box_::into_raw(f),
1636            )
1637        }
1638    }
1639
1640    #[doc(alias = "visible")]
1641    pub fn connect_visible_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1642        unsafe extern "C" fn notify_visible_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1643            this: *mut ffi::GtkTreeViewColumn,
1644            _param_spec: glib::ffi::gpointer,
1645            f: glib::ffi::gpointer,
1646        ) {
1647            let f: &F = &*(f as *const F);
1648            f(&from_glib_borrow(this))
1649        }
1650        unsafe {
1651            let f: Box_<F> = Box_::new(f);
1652            connect_raw(
1653                self.as_ptr() as *mut _,
1654                b"notify::visible\0".as_ptr() as *const _,
1655                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1656                    notify_visible_trampoline::<F> as *const (),
1657                )),
1658                Box_::into_raw(f),
1659            )
1660        }
1661    }
1662
1663    #[doc(alias = "widget")]
1664    pub fn connect_widget_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1665        unsafe extern "C" fn notify_widget_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1666            this: *mut ffi::GtkTreeViewColumn,
1667            _param_spec: glib::ffi::gpointer,
1668            f: glib::ffi::gpointer,
1669        ) {
1670            let f: &F = &*(f as *const F);
1671            f(&from_glib_borrow(this))
1672        }
1673        unsafe {
1674            let f: Box_<F> = Box_::new(f);
1675            connect_raw(
1676                self.as_ptr() as *mut _,
1677                b"notify::widget\0".as_ptr() as *const _,
1678                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1679                    notify_widget_trampoline::<F> as *const (),
1680                )),
1681                Box_::into_raw(f),
1682            )
1683        }
1684    }
1685
1686    #[doc(alias = "width")]
1687    pub fn connect_width_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1688        unsafe extern "C" fn notify_width_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1689            this: *mut ffi::GtkTreeViewColumn,
1690            _param_spec: glib::ffi::gpointer,
1691            f: glib::ffi::gpointer,
1692        ) {
1693            let f: &F = &*(f as *const F);
1694            f(&from_glib_borrow(this))
1695        }
1696        unsafe {
1697            let f: Box_<F> = Box_::new(f);
1698            connect_raw(
1699                self.as_ptr() as *mut _,
1700                b"notify::width\0".as_ptr() as *const _,
1701                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1702                    notify_width_trampoline::<F> as *const (),
1703                )),
1704                Box_::into_raw(f),
1705            )
1706        }
1707    }
1708
1709    #[doc(alias = "x-offset")]
1710    pub fn connect_x_offset_notify<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId {
1711        unsafe extern "C" fn notify_x_offset_trampoline<F: Fn(&TreeViewColumn) + 'static>(
1712            this: *mut ffi::GtkTreeViewColumn,
1713            _param_spec: glib::ffi::gpointer,
1714            f: glib::ffi::gpointer,
1715        ) {
1716            let f: &F = &*(f as *const F);
1717            f(&from_glib_borrow(this))
1718        }
1719        unsafe {
1720            let f: Box_<F> = Box_::new(f);
1721            connect_raw(
1722                self.as_ptr() as *mut _,
1723                b"notify::x-offset\0".as_ptr() as *const _,
1724                Some(std::mem::transmute::<*const (), unsafe extern "C" fn()>(
1725                    notify_x_offset_trampoline::<F> as *const (),
1726                )),
1727                Box_::into_raw(f),
1728            )
1729        }
1730    }
1731}
1732
1733impl Default for TreeViewColumn {
1734    fn default() -> Self {
1735        Self::new()
1736    }
1737}
1738
1739// rustdoc-stripper-ignore-next
1740/// A [builder-pattern] type to construct [`TreeViewColumn`] objects.
1741///
1742/// [builder-pattern]: https://doc.rust-lang.org/1.0.0/style/ownership/builders.html
1743#[must_use = "The builder must be built to be used"]
1744pub struct TreeViewColumnBuilder {
1745    builder: glib::object::ObjectBuilder<'static, TreeViewColumn>,
1746}
1747
1748impl TreeViewColumnBuilder {
1749    fn new() -> Self {
1750        Self {
1751            builder: glib::object::Object::builder(),
1752        }
1753    }
1754
1755    pub fn alignment(self, alignment: f32) -> Self {
1756        Self {
1757            builder: self.builder.property("alignment", alignment),
1758        }
1759    }
1760
1761    /// The [`CellArea`][crate::CellArea] used to layout cell renderers for this column.
1762    ///
1763    /// If no area is specified when creating the tree view column with gtk_tree_view_column_new_with_area()
1764    /// a horizontally oriented [`CellAreaBox`][crate::CellAreaBox] will be used.
1765    pub fn cell_area(self, cell_area: &impl IsA<CellArea>) -> Self {
1766        Self {
1767            builder: self
1768                .builder
1769                .property("cell-area", cell_area.clone().upcast()),
1770        }
1771    }
1772
1773    pub fn clickable(self, clickable: bool) -> Self {
1774        Self {
1775            builder: self.builder.property("clickable", clickable),
1776        }
1777    }
1778
1779    pub fn expand(self, expand: bool) -> Self {
1780        Self {
1781            builder: self.builder.property("expand", expand),
1782        }
1783    }
1784
1785    pub fn fixed_width(self, fixed_width: i32) -> Self {
1786        Self {
1787            builder: self.builder.property("fixed-width", fixed_width),
1788        }
1789    }
1790
1791    pub fn max_width(self, max_width: i32) -> Self {
1792        Self {
1793            builder: self.builder.property("max-width", max_width),
1794        }
1795    }
1796
1797    pub fn min_width(self, min_width: i32) -> Self {
1798        Self {
1799            builder: self.builder.property("min-width", min_width),
1800        }
1801    }
1802
1803    pub fn reorderable(self, reorderable: bool) -> Self {
1804        Self {
1805            builder: self.builder.property("reorderable", reorderable),
1806        }
1807    }
1808
1809    pub fn resizable(self, resizable: bool) -> Self {
1810        Self {
1811            builder: self.builder.property("resizable", resizable),
1812        }
1813    }
1814
1815    pub fn sizing(self, sizing: TreeViewColumnSizing) -> Self {
1816        Self {
1817            builder: self.builder.property("sizing", sizing),
1818        }
1819    }
1820
1821    /// Logical sort column ID this column sorts on when selected for sorting. Setting the sort column ID makes the column header
1822    /// clickable. Set to -1 to make the column unsortable.
1823    pub fn sort_column_id(self, sort_column_id: i32) -> Self {
1824        Self {
1825            builder: self.builder.property("sort-column-id", sort_column_id),
1826        }
1827    }
1828
1829    pub fn sort_indicator(self, sort_indicator: bool) -> Self {
1830        Self {
1831            builder: self.builder.property("sort-indicator", sort_indicator),
1832        }
1833    }
1834
1835    pub fn sort_order(self, sort_order: SortType) -> Self {
1836        Self {
1837            builder: self.builder.property("sort-order", sort_order),
1838        }
1839    }
1840
1841    pub fn spacing(self, spacing: i32) -> Self {
1842        Self {
1843            builder: self.builder.property("spacing", spacing),
1844        }
1845    }
1846
1847    pub fn title(self, title: impl Into<glib::GString>) -> Self {
1848        Self {
1849            builder: self.builder.property("title", title.into()),
1850        }
1851    }
1852
1853    pub fn visible(self, visible: bool) -> Self {
1854        Self {
1855            builder: self.builder.property("visible", visible),
1856        }
1857    }
1858
1859    pub fn widget(self, widget: &impl IsA<Widget>) -> Self {
1860        Self {
1861            builder: self.builder.property("widget", widget.clone().upcast()),
1862        }
1863    }
1864
1865    // rustdoc-stripper-ignore-next
1866    /// Build the [`TreeViewColumn`].
1867    #[must_use = "Building the object from the builder is usually expensive and is not expected to have side effects"]
1868    pub fn build(self) -> TreeViewColumn {
1869        assert_initialized_main_thread!();
1870        self.builder.build()
1871    }
1872}