RenderOptions.SetCacheInvalidationThresholdMinimum Metodo

Definizione

Imposta il valore della proprietà associata CacheInvalidationThresholdMinimum su un oggetto dipendenza specificato.

public:
 static void SetCacheInvalidationThresholdMinimum(System::Windows::DependencyObject ^ target, double cacheInvalidationThresholdMinimum);
public static void SetCacheInvalidationThresholdMinimum (System.Windows.DependencyObject target, double cacheInvalidationThresholdMinimum);
static member SetCacheInvalidationThresholdMinimum : System.Windows.DependencyObject * double -> unit
Public Shared Sub SetCacheInvalidationThresholdMinimum (target As DependencyObject, cacheInvalidationThresholdMinimum As Double)

Parametri

target
DependencyObject

Oggetto dipendenza per cui impostare il valore della proprietà CacheInvalidationThresholdMinimum.

cacheInvalidationThresholdMinimum
Double

Nuovo valore su cui impostare la proprietà.

Eccezioni

Il valore specificato per il parametro target è null.

Esempio

Nell'esempio seguente viene illustrato come usare l'opzione hint per la memorizzazione nella cache per un oggetto DrawingBrush.

DrawingBrush drawingBrush = new DrawingBrush();
            
// Set the caching hint option for the brush.
RenderOptions.SetCachingHint(drawingBrush, CachingHint.Cache);

// Set the minimum and maximum relative sizes for regenerating the tiled brush.
// The tiled brush will be regenerated and re-cached when its size is
// 0.5x or 2x of the current cached size.
RenderOptions.SetCacheInvalidationThresholdMinimum(drawingBrush, 0.5);
RenderOptions.SetCacheInvalidationThresholdMaximum(drawingBrush, 2.0);
Dim drawingBrush As New DrawingBrush()

' Set the caching hint option for the brush.
RenderOptions.SetCachingHint(drawingBrush, CachingHint.Cache)

' Set the minimum and maximum relative sizes for regenerating the tiled brush.
' The tiled brush will be regenerated and re-cached when its size is
' 0.5x or 2x of the current cached size.
RenderOptions.SetCacheInvalidationThresholdMinimum(drawingBrush, 0.5)
RenderOptions.SetCacheInvalidationThresholdMaximum(drawingBrush, 2.0)

Commenti

Utilizzare questo metodo per impostare la CacheInvalidationThresholdMinimum proprietà associata nel codice.

Si applica a

Vedi anche