Could anyone give me some hint about how to use a iOS custom UIView like https://github.com/gshackles/JVFloatSharp in CustomRenderer.
[assembly: ExportRenderer (typeof (JVFloatLabeledEntry), typeof (JVFloatLabeledEntryRenderer))]
namespace DutyFreeCollection.iOS
{
public class JVFloatLabeledEntryRenderer : JVFloatLabeledTextField // What class shoud I inherit?
{
public JVFloatLabeledEntryRenderer (RectangleF frame)
{
const float JVFieldHeight = 44.0f;
const float JVFieldHMargin = 10.0f;
const float JVFieldFontSize = 16.0f;
const float JVFieldFloatingLabelFontSize = 11.0f;
UIColor floatingLabelColor = UIColor.Gray, floatingLabelActiveColor = UIColor.Blue;
Placeholder = "Specific Location (optional)";
Font = UIFont.SystemFontOfSize (JVFieldFontSize);
FloatingLabelFont = UIFont.BoldSystemFontOfSize (JVFieldFloatingLabelFontSize);
FloatingLabelTextColor = floatingLabelColor;
FloatingLabelActiveTextColor = floatingLabelActiveColor;
}
}
- What class should JVFloatLabeledEntryRenderer inherit from?
- JVFloatLabeledTextField doesn't have a ctor with 0 argument, but a CustomRenderer needs a ctor with 0 argument to be used.
Thank you very much.