IReadOnlyRegionEdit Interface

 

Represents a set of read-only region editing operations (creating and removing read-only regions on an ITextBuffer.

Namespace:   Microsoft.VisualStudio.Text
Assembly:  Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)

public interface IReadOnlyRegionEdit : ITextBufferEdit, IDisposable

NameDescription
System_CAPS_pubpropertyCanceled

Determines whether this edit has been canceled.(Inherited from ITextBufferEdit.)

System_CAPS_pubpropertySnapshot

Gets a snapshot of the ITextBuffer at the time this object was created.(Inherited from ITextBufferEdit.)

NameDescription
System_CAPS_pubmethodApply()

Commits all the modifications made with this ITextBufferEdit object to the underlying ITextBuffer. It also causes the ITextBuffer to generate a new snapshot and raise its Changed event if any modifications were made. (Inherited from ITextBufferEdit.)

System_CAPS_pubmethodCancel()

Abandons all modifications started using this ITextBufferEdit object. Any further calls on this object will result in an InvalidOperationException.(Inherited from ITextBufferEdit.)

System_CAPS_pubmethodCreateDynamicReadOnlyRegion(Span, SpanTrackingMode, EdgeInsertionMode, DynamicReadOnlyRegionQuery)

Marks a span of text in this buffer as conditionally read-only, subject to a check performed when the region is queried. The span remains read-only until it is marked as writable or forced writable again.

System_CAPS_pubmethodCreateReadOnlyRegion(Span)

Marks a span of text in this buffer as read-only. The span remains read-only until the IReadOnlyRegion is removed.

System_CAPS_pubmethodCreateReadOnlyRegion(Span, SpanTrackingMode, EdgeInsertionMode)

Marks a span of text in this buffer as read-only. The span remains read-only until it is marked as writable or forced writable again.

System_CAPS_pubmethodDispose()

(Inherited from IDisposable.)

System_CAPS_pubmethodRemoveReadOnlyRegion(IReadOnlyRegion)

Removes the read-only region from the list of read-only regions in this buffer.

Editing positions are specified with respect to the state of the ITextBuffer at the time the IReadOnlyRegionEdit object was created.

At most one ITextBufferEdit object (including IReadOnlyRegionEdit objects) may be active at a given time for a particular ITextBuffer. A IReadOnlyRegionEdit is active as long as it has been neither applied nor canceled. Calling Dispose() on an unapplied IReadOnlyRegionEdit is equivalent to calling Cancel().

The operations performed using this object do not appear in the ITextBuffer until the Apply method has been called.

Return to top
Show: