Top |
TeplFoldRegionTeplFoldRegion — Foldable region in a GtkTextBuffer |
TeplFoldRegion represents a region in a GtkTextBuffer that can be folded.
When a region is being folded, a GtkTextTag with the “invisible”
property is applied to the folded region. The actual start and end position
of this GtkTextTag is respectively at the next new line after the start and
end position of the bounds handed over to tepl_fold_region_set_bounds()
.
TeplFoldRegion * tepl_fold_region_new (GtkTextBuffer *buffer
,const GtkTextIter *start
,const GtkTextIter *end
);
Since: 1.0
GtkTextBuffer *
tepl_fold_region_get_buffer (TeplFoldRegion *fold_region
);
Since: 1.0
gboolean
tepl_fold_region_get_folded (TeplFoldRegion *fold_region
);
Since: 1.0
void tepl_fold_region_set_folded (TeplFoldRegion *fold_region
,gboolean folded
);
Folds or unfolds the region.
Since: 1.0
gboolean tepl_fold_region_get_bounds (TeplFoldRegion *fold_region
,GtkTextIter *start
,GtkTextIter *end
);
Obtains iterators pointing to the start and end of the TeplFoldRegion.
Since: 1.0
void tepl_fold_region_set_bounds (TeplFoldRegion *fold_region
,const GtkTextIter *start
,const GtkTextIter *end
);
Sets the start and end of the TeplFoldRegion.
Since: 1.0
“buffer”
property“buffer” GtkTextBuffer *
The GtkTextBuffer where the fold region is applied. The TeplFoldRegion object has a weak reference to the buffer.
Owner: TeplFoldRegion
Flags: Read / Write / Construct Only
Since: 1.0
“folded”
property“folded” gboolean
Whether the TeplFoldRegion is folded or not.
Owner: TeplFoldRegion
Flags: Read / Write
Default value: FALSE
Since: 1.0