Comments (10)
from androidwheelview.
如何实现居中对齐呢?
from androidwheelview.
这个 -> LoopView.java
是我之前同时做的另一个反混淆工程,做了居中处理。
可以参考绘制文字用的画笔的初始化和onDraw方法里面绘制文字部分的代码。
概括来说就是指定画笔的文字对齐为居中,然后绘制原点从左下角改为中间。
另外中间项放大的效果我注释掉了,在78行,需要的话可以自行处理。
from androidwheelview.
@dotfeng 改成居中显示了
@mlxy 为啥你可以直接提交代码,而我却不行呢,平时工作中用svn,没用git。
from androidwheelview.
@mr235 『直接提交代码』是指什么……?
from androidwheelview.
@mlxy 我得pull requests才能合到 weidongjian的主线上啊,看你好像是直接就能提交上去了,你的名字都在他的contributors里,我的好像没有
from androidwheelview.
是要PR然后被合并才能提交上的,我上面发的是当初我自己克隆的工程
另外想要直接提交也是可以的,在repo设置的Collaborators里加上的人貌似就可以直接push了
from androidwheelview.
@mlxy 谢谢啦,还玩不好github
from androidwheelview.
onmeasure 中添加了
switch(widthMode){
case MeasureSpec.AT_MOST:
measuredWidth = maxTextWidth + paddingLeft + paddingRight;
break;
case MeasureSpec.EXACTLY:
measuredWidth = widthSize;
if(paddingLeft == 0 || paddingRight == 0) {
paddingLeft = (measuredWidth - maxTextWidth) / 2;
paddingRight = paddingLeft;
}
break;
case MeasureSpec.UNSPECIFIED:
measuredWidth = maxTextWidth + paddingLeft + paddingRight;
break;
}
另
public final void setInitPosition(int initPosition) {
this.initPosition = initPosition;
totalScrollY = 0;//popup场景
}
from androidwheelview.
增加了一个设置scaleX的方法,设置为1,折没有错位效果
from androidwheelview.
Related Issues (20)
- onSelectedItemClick HOT 2
- 设置控件大小后 文字 线 都有问题 HOT 1
- Regarding Changing Font HOT 3
- How to setInitPosition as float value?
- 获取的下标不正确 HOT 2
- 最新版得sample。setCurrentPosition(0)还是无效啊 HOT 6
- 建议把中间选中的item加个背景色属性设置
- 莫名其妙的获取到下标为-1 HOT 1
- setCurrentPosition,getSeletedItem 乱序 HOT 4
- setCenterTextColor报空指针 HOT 1
- 为什么setItemsVisibleCount不能是双数 HOT 1
- 有空指针错误 HOT 1
- getSelectedItem 获取位置异常
- 建议增加一个选项,“是否使用3D”,不使用可以平铺,现在很多设计都是扁平化的 HOT 1
- 我刚修复了LoopView中setCurrentPosition不触发OnItemSelectedListener的问题 HOT 1
- setCurrentPosition设置相同的position,无效 HOT 1
- 初始数据为空 添加了awv_lineSpace 位置异常 HOT 1
- 问题1:用户按住滚轮拖拽结束后,没有再返回停止滚动状态
- 问题2:java代码中调用了setNotLoop()方法后,没有恢复循环滚动的方法
- 仓库地址不能用啊 大佬 引用找不到你的自定义类啊
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from androidwheelview.