Paint Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Paint() |
Create a new paint with default settings. |
Paint(Paint) |
Create a new paint, initialized with the attributes in the specified paint parameter. |
Paint(PaintFlags) |
Create a new paint with the specified flags. |
Paint(IntPtr, JniHandleOwnership) |
A constructor used when creating managed representations of JNI objects; called by the runtime. |
Paint()
Create a new paint with default settings.
[Android.Runtime.Register(".ctor", "()V", "")]
public Paint ();
- Attributes
Remarks
Create a new paint with default settings.
On devices running Build.VERSION_CODES#O
and below, hardware accelerated drawing always acts as if #FILTER_BITMAP_FLAG
is set. On devices running Build.VERSION_CODES#Q
and above, FILTER_BITMAP_FLAG
is set by this constructor, and it can be cleared with #setFlags
or #setFilterBitmap
. On devices running Build.VERSION_CODES#S
and above, ANTI_ALIAS_FLAG
is set by this constructor, and it can be cleared with #setFlags
or #setAntiAlias
.
Java documentation for android.graphics.Paint.Paint()
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
Paint(Paint)
Create a new paint, initialized with the attributes in the specified paint parameter.
[Android.Runtime.Register(".ctor", "(Landroid/graphics/Paint;)V", "")]
public Paint (Android.Graphics.Paint? paint);
[<Android.Runtime.Register(".ctor", "(Landroid/graphics/Paint;)V", "")>]
new Android.Graphics.Paint : Android.Graphics.Paint -> Android.Graphics.Paint
Parameters
- paint
- Paint
Existing paint used to initialized the attributes of the new paint.
- Attributes
Remarks
Create a new paint, initialized with the attributes in the specified paint parameter.
Java documentation for android.graphics.Paint.Paint(android.graphics.Paint)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
Paint(PaintFlags)
Create a new paint with the specified flags.
[Android.Runtime.Register(".ctor", "(I)V", "")]
public Paint (Android.Graphics.PaintFlags flags);
[<Android.Runtime.Register(".ctor", "(I)V", "")>]
new Android.Graphics.Paint : Android.Graphics.PaintFlags -> Android.Graphics.Paint
Parameters
- flags
- PaintFlags
initial flag bits, as if they were passed via setFlags().
- Attributes
Remarks
Create a new paint with the specified flags. Use setFlags() to change these after the paint is created.
On devices running Build.VERSION_CODES#O
and below, hardware accelerated drawing always acts as if #FILTER_BITMAP_FLAG
is set. On devices running Build.VERSION_CODES#Q
and above, FILTER_BITMAP_FLAG
is always set by this constructor, regardless of the value of flags
. It can be cleared with #setFlags
or #setFilterBitmap
.
Java documentation for android.graphics.Paint.Paint(int)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
Paint(IntPtr, JniHandleOwnership)
A constructor used when creating managed representations of JNI objects; called by the runtime.
protected Paint (IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Android.Graphics.Paint : nativeint * Android.Runtime.JniHandleOwnership -> Android.Graphics.Paint
Parameters
- transfer
- JniHandleOwnership
A JniHandleOwnershipindicating how to handle javaReference
Remarks
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.