android - 为什么我的 ElegantNumberButton 没有显示 +(加号) 符号?
问题描述
我的xml代码
<com.cepheuen.elegantnumberbutton.view.ElegantNumberButton
android:id="@+id/number_button"
android:layout_width="100dp"
android:layout_height="30dp"
android:layout_marginBottom="18dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
app:backGroundColor="@color/colorAccent"
app:finalNumber="20"
app:initialNumber="1"
app:textSize="8sp"/>
我正在使用 ElegantNumberButton 那个版本:
implementation 'com.cepheuen.elegant-number-button:lib:1.0.2'
有任何版本问题吗?
解决方案
我像@Matpag 说的那样解决了它
<com.cepheuen.elegantnumberbutton.view.ElegantNumberButton
android:id="@+id/number_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="18dp"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
app:backGroundColor="@color/colorAccent"
app:finalNumber="20"
app:initialNumber="1"
app:textSize="8sp"/>
你不能改变android:layout_width
&android:layout_height
推荐阅读
- vb.net - 无法在 VB.Net 2005 中将字符串转换为日期。尝试了 Convert.ToDateTime、ParseExact。我在任何地方都找不到类似的问题。需要帮助
- java - 从 ViewPager 迁移到 ViewPager2 时出现问题
- ios - 如何使 UIDatePicker 标签在 Xamarin.ios 中仍然不可见?
- rdp - 使用 Windows 登录的 RDP 会话 (freerdp) (Thinstation Image)
- javascript - 在 swiper 中使用不同的比例缩放
- python - python循环excel单元格并将行数据导出到文本文件
- css - Tailwinds dark:hidden / dark:block 不会覆盖它自己的隐藏选择器
- c# - 如何在 C# 中将值添加到组合框中?
- lua - 空闲动画无法正常播放(roblox)
- python - 在numpy数组中的多个维度上应用函数