GdPicture.NET.14
GdPicture14 Namespace / GdViewer Class / DisplayQualityAuto Property
Example





In This Topic
DisplayQualityAuto Property (GdViewer)
In This Topic
Specifies if the level of displaying quality according to the used algorithm when manipulating with images is automatic or not.

If you turn off the automatic level of displaying quality by setting this property to false, the previously defined value of the DisplayQuality property other than automatic is used.

Syntax
'Declaration
 
Public Property DisplayQualityAuto As Boolean
public bool DisplayQualityAuto {get; set;}
public read-write property DisplayQualityAuto: Boolean; 
public function get,set DisplayQualityAuto : boolean
public: __property bool get_DisplayQualityAuto();
public: __property void set_DisplayQualityAuto( 
   bool value
);
public:
property bool DisplayQualityAuto {
   bool get();
   void set (    bool value);
}

Property Value

The default value is true.
Remarks
Just to inform you, that the previously defined value (initially set by the toolkit) of the DisplayQuality property is DisplayQuality.DisplayQualityBicubicHQ if you turn off the automatic level without previously manipulating with that property. For more details please refer to the attached example below.
Example
How to utilize this property in your GdViewer control.
'We assume that the GdViewer1 control has been properly integrated
'and your document has been properly displayed as well.
            
'Without changing the default settings.
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
GdViewer1.DisplayQualityAuto = False
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
GdViewer1.DisplayQualityAuto = True
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
            
'Setting some custom value.
GdViewer1.DisplayQuality = DisplayQuality.DisplayQualityBilinearHQ
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
GdViewer1.DisplayQualityAuto = True
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
GdViewer1.DisplayQualityAuto = False
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
            
'Changing to the automatic level directly.
GdViewer1.DisplayQuality = DisplayQuality.DisplayQualityAutomatic
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
'Turning off the automatic level.
GdViewer1.DisplayQualityAuto = False
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto")
//We assume that the GdViewer1 control has been properly integrated
//and your document has been properly displayed as well.
            
//Without changing the default settings.
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
GdViewer1.DisplayQualityAuto = false;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
GdViewer1.DisplayQualityAuto = true;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
            
//Setting some custom value.
GdViewer1.DisplayQuality = DisplayQuality.DisplayQualityBilinearHQ;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
GdViewer1.DisplayQualityAuto = true;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
GdViewer1.DisplayQualityAuto = false;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
            
//Changing to the automatic level directly.
GdViewer1.DisplayQuality = DisplayQuality.DisplayQualityAutomatic;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
//Turning off the automatic level.
GdViewer1.DisplayQualityAuto = false;
MessageBox.Show("DisplayQuality = " + GdViewer1.DisplayQuality.ToString(), "GdViewer.DisplayQualityAuto");
See Also