<ThreadSafetyStatement>Gtk# is thread aware, but not thread safe; See the <linklocation="node:gtk-sharp/programming/threads">Gtk# Thread Programming</link> for details.</ThreadSafetyStatement>
<summary>Moves backward to the next toggle (on or off) of the <seecref="T:Gtk.TextTag"/> tag, or to the next toggle of any tag if tag is <seelangword="null"/>.</summary>
<paramname="tag">a <seecref="T:Gtk.TextTag"/> or <seelangword="null"/></param>
<returns> whether we found a tag toggle before iter</returns>
<remarks>If no matching tag toggles are found, returns <seelangword="false"/>, otherwise <seelangword="true"/>. Does not return toggles located at iter, only toggles before iter. Sets iter to the location of the toggle, or the start of the buffer if no toggle is found.</remarks>
<summary>Moves backward to the previous word start.</summary>
<returns>
<seelangword="true"/> if iter moved and is not the end iterator</returns>
<remarks>(If iter is currently on a word start, moves backward to the next one after that.) Word breaks are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango word break algorithms).</remarks>
<summary>Moves forward to the next sentence end.</summary>
<returns>
<seelangword="true"/> if iter moved and is not the end iterator</returns>
<remarks>If iter is at the end of a sentence, moves to the next end of sentence. Sentence boundaries are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango text boundary algorithms).</remarks>
<remarks>That is, ensures that first and second are in sequence. Most text buffer functions that take a range call this automatically on your behalf, so there's no real reason to call it yourself in those cases. There are some exceptions, such as <seecref="M:Gtk.TextIter.InRange()"/>, that expect a pre-sorted range.</remarks>
<remarks>Returns <seelangword="true"/> if iter could be moved; i.e. if iter was at character offset 0, this function returns <seelangword="false"/>. Therefore if iter was already on line 0, but not at the start of the line, iter is snapped to the start of the line and the function returns <seelangword="true"/>. (Note that this implies that in a loop calling this function, the line number may not change on every iteration, if your first iteration is on line 0.)</remarks>
<summary>Like <seecref="M:Gtk.TextIter.GetSlice()"/>, but invisible text is not included.</summary>
<paramname="end"> iterator at end of range</param>
<returns> slice of text from the buffer</returns>
<remarks> Invisible text is usually invisible because a <seecref="T:Gtk.TextTag"/> with the "invisible" attribute turned on has been applied to it.</remarks>
<summary>Returns the text in the given range.</summary>
<paramname="end"> iterator at end of a range</param>
<returns> slice of text from the buffer</returns>
<remarks>A "slice" is an array of characters encoded in UTF-8 format, including the Unicode "unknown" character 0xFFFC for iterable non-character elements in the buffer, such as images. Because images are encoded in the slice, byte and character offsets in the returned array will correspond to byte offsets in the text buffer. Note that 0xFFFC can occur in normal text as well, so it is not a reliable indicator that a pixbuf or widget is in the buffer.</remarks>
<summary>Moves forward to the next word end.</summary>
<returns>
<seelangword="true"/> if iter moved and is not the end iterator</returns>
<remarks>(If iter is currently on a word end, moves forward to the next one after that.) Word breaks are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango word break algorithms).</remarks>
<summary>Advances iter, calling pred on each character.</summary>
<paramname="pred"> a function to be called on each character</param>
<paramname="user_data"> user data for pred</param>
<paramname="limit"> search limit, or <seelangword="null"/> for none</param>
<returns> whether a match was found</returns>
<remarks>If pred returns <seelangword="true"/>, returns <seelangword="true"/> and stops scanning. If pred never returns <seelangword="true"/>, iter is set to limit if limit is non-<seelangword="null"/>, otherwise to the end iterator.</remarks>
<summary>Determines whether iter ends a natural-language word.</summary>
<returns>
<seelangword="true"/> if iter is at the end of a word</returns>
<remarks>Word breaks are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango word break algorithms).</remarks>
<summary>Returns whether the character at iter is within an editable region of text.</summary>
<paramname="default_setting">
<seelangword="true"/> if text is editable by default</param>
<returns> whether iter is inside an editable range</returns>
<remarks>
<para>
Non-editable text is "locked" and cannot be changed by the user via <seecref="T:Gtk.TextView"/>. This function is simply a convenience wrapper around <seecref="M:Gtk.TextIter.GetAttributes()"/>. If no tags applied to this text effect editability, <paramrefname="default_setting"/> will be returned.
</para>
<para>
You do not want to use this function to decide whether text can be inserted at iter, because for insertion you do not want to know whether the char at iter is inside an editable range, you want to know whether a new character inserted at iter would be inside an editable range. Use <seecref="M:Gtk.TextIter.CanInsert()"/> to handle this case.
<summary>Moves this iterator forward by one character offset.</summary>
<returns>A boolean: <seelangword="true"/> if the iterator moved and is dereferenceable.</returns>
<remarks>Note that images embedded in the buffer occupy 1 character slot, so this may actually move onto an image instead of a character, if you have images in your buffer. If this object is the end iterator or one character before it, the object will now point at the end iterator, and return <seelangword="false"/> for convenience when writing loops.</remarks>
<remarks>Moves count lines backward, if possible (if count would move past the start or end of the buffer, moves to the start or end of the buffer). The return value indicates whether the iterator moved onto a dereferenceable position; if the iterator didn't move, or moved onto the end iterator, then <seelangword="false"/> is returned. If count is 0, the function does nothing and returns <seelangword="false"/>. If count is negative, moves forward by 0 - count lines.</remarks>
<remarks>Returns <seelangword="true"/> if iter points to the start of the paragraph delimiter characters for a line (delimiters will be either a newline, a carriage return, a carriage return followed by a newline, or a Unicode paragraph separator character). Note that an iterator pointing to the \n of a \r\n pair will not be counted as the end of a line, the line ends before the \r. The end iterator is considered to be at the end of a line, even though there are no paragraph delimiter chars there.</remarks>
<summary>Calls <seecref="M:Gtk.TextIter.BackwardSentenceStart()"/> up to <paramrefname="count"/> times, or until it returns <seelangword="false"/>.</summary>
<paramname="count"> number of sentences to move</param>
<returns>
<seelangword="true"/> if iter moved and is not the end iterator</returns>
<remarks>If <paramrefname="count"/> is negative, moves forward instead of backward.</remarks>
<seelangword="true"/> if the iterators point to the same place in the buffer</returns>
<remarks>This function is very fast; you can expect it to perform better than e.g. getting the character offset for each iterator and comparing the offsets yourself. Also, it's a bit faster than <seecref="M:Gtk.TextIter.Compare()"/>.</remarks>
<summary>Determines whether iter begins a sentence.</summary>
<returns>
<seelangword="true"/> if iter is at the start of a sentence.</returns>
<remarks>Sentence boundaries are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango text boundary algorithms).</remarks>
<summary>Moves forward to the next toggle (on or off) of the <seecref="T:Gtk.TextTag"/> tag, or to the next toggle of any tag if tag is <seelangword="null"/>.</summary>
<paramname="tag">a <seecref="T:Gtk.TextTag"/> or <seelangword="null"/></param>
<returns> whether we found a tag toggle after iter</returns>
<remarks>If no matching tag toggles are found, returns <seelangword="false"/>, otherwise <seelangword="true"/>. Does not return toggles located at iter, only toggles after iter. Sets iter to the location of the toggle, or to the end of the buffer if no toggle is found.</remarks>
<seelangword="true"/> if values was modified</returns>
<remarks>
<para>
The values parameter should be initialized to the default settings you wish to use if no tags are in effect. You would typically obtain the defaults from <seecref="M:Gtk.TextView.GetDefaultAttributes()"/>.
</para>
<para>
<seecref="M:Gtk.TextIter.GetAttributes()"/> will modify values, applying the effects of any tags present at iter. If any tags affected values, the function returns <seelangword="true"/>.
<summary>Returns text in the given range.</summary>
<paramname="end"> iterator at end of a range</param>
<returns> the string from the buffer</returns>
<remarks>If the range contains non-text elements such as images, the character and byte offsets in the returned string will not correspond to character and byte offsets in the buffer. If you want offsets to correspond, see <seecref="M:Gtk.TextIter.GetSlice()"/>.</remarks>
<summary>Moves iter forward by a single cursor position.</summary>
<returns>
<seelangword="true"/> if we moved and the new position is dereferenceable</returns>
<remarks>Cursor positions are (unsurprisingly) positions where the cursor can appear. Perhaps surprisingly, there may not be a cursor position between all characters. The most common example for European languages would be a carriage return/newline sequence. For some Unicode characters, the equivalent of say the letter "a" with an accent mark will be represented as two characters, first the letter then a "combining mark" that causes the accent to be rendered; so the cursor cannot go between those two characters.</remarks>
<summary>Moves count lines forward, if possible (if count would move past the start or end of the buffer, moves to the start or end of the buffer).</summary>
<paramname="count"> number of lines to move forward</param>
<returns> whether iter moved and is dereferenceable</returns>
<remarks>The return value indicates whether the iterator moved onto a dereferenceable position; if the iterator didn't move, or moved onto the end iterator, then <seelangword="false"/> is returned. If count is 0, the function does nothing and returns <seelangword="false"/>. If count is negative, moves backward by 0 - count lines.</remarks>
<remarks>Returns <seelangword="true"/> if there was a next line to move to, and <seelangword="false"/> if iter was simply moved to the end of the buffer and is now not dereferenceable, or if iter was already at the end of the buffer.</remarks>
<remarks>Moves count characters backward, if possible (if count would move past the start or end of the buffer, moves to the start or end of the buffer). The return value indicates whether the iterator moved onto a dereferenceable position; if the iterator didn't move, or moved onto the end iterator, then <seelangword="false"/> is returned. If count is 0, the function does nothing and returns <seelangword="false"/>.</remarks>
<summary>Moves backward to the previous sentence start; if iter is already at the start of a sentence, moves backward to the next one.</summary>
<returns>
<seelangword="true"/> if iter moved and is not the end iterator</returns>
<remarks>Sentence boundaries are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango text boundary algorithms).</remarks>
<summary>Determines whether iter begins a natural-language word.</summary>
<returns>
<seelangword="true"/> if iter is at the start of a word</returns>
<remarks>Word breaks are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango word break algorithms).</remarks>
<summary>Returns <seelangword="true"/> if tag is toggled on at exactly this point.</summary>
<paramname="tag">a <seecref="T:Gtk.TextTag"/> or <seelangword="null"/></param>
<returns> whether iter is the start of a range tagged with tag</returns>
<remarks>If tag is <seelangword="null"/>, returns <seelangword="true"/> if any tag is toggled on at this point. Note that the <seecref="M:Gtk.TextIter.BeginsTag()"/> returns <seelangword="true"/> if iter is the start of the tagged range; <seecref="M:Gtk.TextIter.HasTag()"/> tells you whether an iterator is within a tagged range.</remarks>
<summary>Like <seecref="M:Gtk.TextIter.GetText()"/>, but invisible text is not included.</summary>
<paramname="end"> iterator at end of range</param>
<returns> string containing visible text in the range</returns>
<remarks>Invisible text is usually invisible because a <seecref="T:Gtk.TextTag"/> with the "invisible" attribute turned on has been applied to it.</remarks>
<summary>Moves the iterator to point to the paragraph delimiter characters, which will be either a newline, a carriage return, a carriage return/newline in sequence, or the Unicode paragraph separator character.</summary>
<returns>
<seelangword="true"/> if we moved and the new location is not the end iterator</returns>
<remarks> If the iterator is already at the paragraph delimiter characters, moves to the paragraph delimiter characters for the next line. If iter is on the last line in the buffer, which does not end in paragraph delimiters, moves to the end iterator (end of the last line), and returns <seelangword="false"/>.</remarks>
<summary>Determines whether iter ends a sentence.</summary>
<returns>
<seelangword="true"/> if iter is at the end of a sentence.</returns>
<remarks>Sentence boundaries are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango text boundary algorithms).</remarks>
<summary>Determines whether iter is inside a sentence (as opposed to in between two sentences, e.g. after a period and before the first letter of the next sentence).</summary>
<returns>
<seelangword="true"/> if iter is inside a sentence.</returns>
<remarks>Sentence boundaries are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango text boundary algorithms).</remarks>
<remarks>Returns <seelangword="true"/> if movement was possible; if iter was the first in the buffer (character offset 0), this returns <seelangword="false"/> for convenience when writing loops.</remarks>
<summary>Returns <seelangword="true"/> if tag is toggled off at exactly this point.</summary>
<paramname="tag">a <seecref="T:Gtk.TextTag"/> or <seelangword="null"/></param>
<returns> whether iter is the end of a range tagged with tag</returns>
<remarks>If tag is <seelangword="null"/>, returns <seelangword="true"/> if any tag is toggled off at this point. Note that the <seecref="T:Gtk.TextIter.EndsTag()"/> returns <seelangword="true"/> if iter is the end of the tagged range; <seecref="T:Gtk.TextIter.HasTag()"/> tells you whether an iterator is within a tagged range.</remarks>
<summary>Moves count characters if possible (if count would move past the start or end of the buffer, moves to the start or end of the buffer).</summary>
<paramname="count"> number of characters to move, may be negative</param>
<returns> whether iter moved and is dereferenceable</returns>
<remarks>The return value indicates whether the new position of iter is different from its original position, and dereferenceable (the last iterator in the buffer is not dereferenceable). If count is 0, the function does nothing and returns <seelangword="false"/>.</remarks>
<summary>Considering the default editability of the buffer, and tags that affect editability, determines whether text inserted at iter would be editable.</summary>
<paramname="default_editability">
<seelangword="true"/> if text is editable by default</param>
<returns> whether text inserted at iter would be editable</returns>
<remarks>If text inserted at iter would be editable then the user should be allowed to insert text at iter. <seecref="T:Gtk.TextBuffer.InsertInteractive()"/> uses this function to decide whether insertions are allowed at a given position.</remarks>
<summary>A qsort()-style function that returns negative if lhs is less than rhs, positive if lhs is greater than rhs, and 0 if they are equal.</summary>
<summary>Determines whether iter is inside a natural-language word (as opposed to say inside some whitespace).</summary>
<returns>
<seelangword="true"/> if iter is inside a word</returns>
<remarks>Word breaks are determined by Pango and should be correct for nearly any language (if not, the correct fix would be to the Pango word break algorithms).</remarks>
<summary>Returns the number of bytes from the start of the line to the given iter, not counting bytes that are invisible due to tags with the "invisible" flag toggled on.</summary>
<returns> distance from start of line, in bytes</returns>
<remarks>Remember that <seecref="T:Gtk.TextBuffer"/> encodes text in UTF-8, and that characters can require a variable number of bytes to represent.</remarks>
<summary>Returns the offset in characters from the start of the line to the given iter, not counting characters that are invisible due to tags with the "invisible" flag toggled on.</summary>
<summary>Searches forward for <paramrefname="str"/>.</summary>
<paramname="str"> a search string</param>
<paramname="flags"> flags affecting how the search is done</param>
<paramname="match_start"> return location for start of match, or <seelangword="null"/></param>
<paramname="match_end"> return location for end of match, or <seelangword="null"/></param>
<paramname="limit"> bound for the search, or <seelangword="null"/> for the end of the buffer</param>
<returns> whether a match was found</returns>
<remarks>
<para>
Any match is returned by setting <paramrefname="match_start"/> to the first character of the match and <paramrefname="match_end"/> to the first character after the match. The search will not continue past limit. Note that a search is a linear or O(n) operation, so you may wish to use limit to avoid locking up your UI on large buffers.
</para>
<para>
If the GTK_TEXT_SEARCH_VISIBLE_ONLY flag is present, the match may have invisible text interspersed in str. i.e. str will be a possibly-noncontiguous subsequence of the matched range. similarly, if you specify GTK_TEXT_SEARCH_TEXT_ONLY, the match may have pixbufs or child widgets mixed inside the matched range. If these flags are not given, the match must be exact; the special 0xFFFC character in str will match embedded pixbufs or child widgets.
<remarks>Because marks are not iterable (they do not take up any "space" in the buffer, they are just marks in between iterable locations), multiple marks can exist in the same place. The returned list is not in any meaningful order.</remarks>
<remarks>(If toggled_on is <seelangword="true"/>, the list contains tags that are toggled on.) If a tag is toggled on at iter, then some non-empty range of characters following iter has that tag applied to it. If a tag is toggled off, then some non-empty range following iter does not have the tag applied to it.</remarks>