augustrush / arsegmentpager Goto Github PK
View Code? Open in Web Editor NEWsegment tab controller with parallax Header
License: MIT License
segment tab controller with parallax Header
License: MIT License
If you have more than one section in your tableview, and you have header titles for the sections, the top section gets stuck in the middle of the screen.
Hi!
Thanks for this third part, I'm developing a custom header like as project example, I have copied the same code but the headImageView doesn't resize, I have checked that updateHeadPhotoWithTopInset method did not fire too.
I'm new in objective-c, What could I be doing wrong??
首先非常感谢@AugustRush开源了这么好用的框架,最近有时间看了一下源码,主要的实现逻辑是在kvo的-(void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context的这个方法里,根据scrollView的偏移量来改变headerView的高度约束,这样会导致一个小问题,就是在自定义headerView的时候,headerView中子view的约束如果不是和bottom关联而是和top关联的就会出现一些小问题(或者自定义headerView没有使用约束布局)。不知道是否能通过修改headerView的top约束来实现类似的效果。
Hi, with the new code for the scrolling, is there a way to disable the header stretch?
thx
there is problem within init()
method they cant setViewControllers that shows init error please it
Hey there! Are there anywhere I can find some example code? :-) Or maybe just some documentation.
Thanks for this library though, it looks exactly like what I need!
I import this library in my project last year, it worked well. But now when i running 'pod update' command, the library update and it crashes.
The error is that my project could not find the ARSegmentView object property of the UIViewController. I found that the latest library set this property private, i can not get the property directly.
So i suggest that author should keep older version, otherwise it would take much time to modify the project to adjust the latest library.
can you plz make the scroller like the twiteer app,
when you scroll the header image disappar and a title show on the navigation bar
Hi,
First let me thank you for this amazing third part,
but i have a problem, how i can change segment title
Hi,
I would like to thank you first of this nice library, is it possible to add horizontal scroll between segments ? I mean changing the page not only by pressing segments also by pan (swipe) right/left.
If it is possible, how could we implement it?
Regards
想搞支持滑动切换page页面,不知道从哪下手。
Hello, I'm trying to use this library in this so In mainView.h file that inherits from ARSegmentPageController I've added this code :
-(id)initWithCoder:(NSCoder *)aDecoder{
return [self init];
}
This will allow to instantiate the view from storyboard as in the programmatically way *mainView view = [[mainView alloc] init]
And then in storyboard I set parent class of Main viewController to mainView.h
This worked but there's some strange behavior the segmentedController was duplicated one move up and down normally and the other stay in same initialPosition check the image :
你好,现在用到你的项目,使用kvo不能监听segmentTopInset值得变化。我把demo里面的CustomHeaderViewController这个自定义头部视图的类拖到我的项目里面测试,也是监听不了segmentTopInset的变化。我把我自己自定义的头部视图替换demo里面的自定义头部视图,在demo里面运行时可以监听到segmentTopInset的变化。不知道这是什么原因引起的
在这句[scrollView
setContentInset:UIEdgeInsetsMake(_originalTopInset, 0, bottomInset, 0)];后面添加了修改滚动条偏移的代码:
scrollView.scrollIndicatorInsets=UIEdgeInsetsMake(_originalTopInset, 0, bottomInset, 0);
在临界点位置轻微下拉tableview的时候headerView和segmentView会出现轻微抖动,影响体验。
你好,请教一个问题,如果headerView的高度是根据后台请求的数据在决定的,是动态变化的,该如何实现该功能呢?谢谢!
I added this line in my viewDidLoad :
[self addObserver:self forKeyPath:@"segmentToInset" options:NSKeyValueObservingOptionNew context:NULL];
But when call comes here on this line
CGFloat topInset = [change[NSKeyValueChangeNewKey] floatValue];
Its crashes with this message.
-[NSConcreteValue floatValue]: unrecognized selector sent to instance 0x7fc7ebed4aa0
Can you explain what I am doing wrong here? Or can you put your customised header code in sample project that would really help.
我自定义了一个headerview,包含有button,当我需要滑动headerview的时候,我看demo是重写了hittest方法,但是这样的话button的点击事件就失效了,有什么别的办法让header可以拖动,并且不影响button点击吗?感谢分享
Current If CustomHeader have image, app run perfect. But If I have a UIScrollView in CustomHeader and scrollview have many image (scroll horizontal image in scrollview), I can't scroll table from touch on CustomHeader. I debug and I see app don't call in funtion if I scroll from CustomHeader
-(void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context
Please help me check it.
在iOS11的时候,试图加载完之后,会在segmentView上加一个UIToolBar,就覆盖掉了本身的点击事件,没有人遇到吗???
点击push按钮,不拖动然后 第一个列表跳转到第三个列表,,第三列加载header显示错乱
Hi! when a function with this code is called:
self.publicProfileVC = [[PublicProfileVC alloc] init];
[self.navController pushViewController:self.publicProfileVC animated:YES];
I'm getting this error:
Uncaught exception: Cannot remove an observer <PublicProfileVC 0x182590f0> for the key path "segmentTopInset" from <PublicProfileVC 0x182590f0> because it is not registered as an observer.
What may be causing this error? thanks!
自定义了head之后 滑动head事件不能用了,这个有什么解决办法么
First of all I really want to thank you for this great controller. Please can you help me to customize your controller basically I want to add two behaviors :
This two behaviors exists in this controller, See the third example please :
https://github.com/quemb/QMBParallaxScrollViewController
Anyone can help me, I may be a good feature for other users.
你好,我想在tableview的section上添加一个header,用于显示排序选项,并能停靠在顶部的segmentcontrol下面。
但是现在加上去之后,发现tableview的section header 不会跟着移动上去,往下拉的时候可以。能看下怎么解决吗?非常感谢。
on the custom controller (red rectangle) in the demo i can scroll down back to show the header
我自定义了一个headerView,现在有一个需求是不仅滑动scrollView时,整体向上偏移。当滑动那个headerView时,也要求有同样的效果,请问应该怎么实现?我还是个菜鸟,麻烦给个思路也行,先谢谢了🙏!
这个怎么使用的啊。。。demo里边没啥注释。。。。很喜欢这种效果的。希望大神指点一二
could you plz make it pod
My profile view controller is embedded inside the Navigation controller and when I push pager its shows up with coloured navigation bar. While in demo its transparent one. How one can achieve that?
点击push第一个了列表滑动至底部,然后切换第二个列表,如果第二个列表数据不足一屏,拖动会有问题
Hi,
Your podspec seems to be fine, but the spec itself hasn't been added to cocoapod trunk and is therefore results in an unable to find 'ARSegmentPage' pod when trying to install it.
Proof: https://cocoapods.org/?q=arsegmentpager
Cheers,
Max.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.