UIScrollView采用“U”字形

时间:2011-01-03 18:10:10

标签: iphone uikit uiscrollview

我想知道是否可以创建一个具有“U”形状或由任何其他曲线图案组成的滚动视图?

任何想法?

2 个答案:

答案 0 :(得分:0)

您可以写一个Custom Gesture Recognizer来识别“U”。

它涉及实施以下方法:

- (void)reset;
- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event;
- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event;
- (void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event;
- (void)touchesCancelled:(NSSet *)touches withEvent:(UIEvent *)event;

并使用几何体来查找您正在寻找的模式。

答案 1 :(得分:0)

对于渲染,可能某种变换层可能会有所帮助。但是,对于触摸处理,您可能是独立的。