ios - 如何在 xamarin ios 中有浮动标签文本框
问题描述
嗨我已经尝试集成MaterialComponentsXamarin我将在其中动态生成文本框我已经应用了以下代码但是当我关注文本框时我看不到浮动标签
TextField text = new TextField();
text.Placeholder = "this is floating label";
解决方案
您需要TextInputController
使用对您的TextField
.
例如:
var _ = new TextInputControllerOutlined(text);
原始的 swift 教程展示了这一点:https ://codelabs.developers.google.com/codelabs/mdc-101-swift/#2
推荐阅读
- android - 将特征添加到android
- android - 如何从联系人列表中启用多项选择
- javascript - 如何为过滤结果选择更多复选框值?
- python - 使用 Regex、python 循环遍历 XPath 列表
- excel - 将微调按钮分配给文本框
- android - 无法在 recyclerview Android 中启动新活动 onItemClick
- vb.net - DynamicDatabaseFactory.CreateDatabase 连接字符串解析出错
- amazon-dynamodb - 生成不重复的数据并保存在 DynamoDB 中
- python - 在python中将布尔值归因于变量和将字符串归因于变量之间是否存在显着的速度差异?
- powershell - 使用 for 循环复制具有递增值的属性