GithubHelp home page GithubHelp logo

bestwnh / igldropdownmenu Goto Github PK

View Code? Open in Web Editor NEW
1.2K 44.0 161.0 3.6 MB

An iOS drop down menu with pretty animation and easy to customize.

Home Page: https://www.cocoacontrols.com/controls/igldropdownmenu

License: MIT License

Ruby 1.51% Objective-C 98.49%
animation objective-c dropdown dropdownmenu ios customize pretty easy menu

igldropdownmenu's People

Contributors

bestwnh avatar lukasthoms avatar thepsguy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

igldropdownmenu's Issues

TextLabel Customization Request

Good Day,

Thank you for the brilliant control. Its a real lifesaver.

I am trying to customize the textlabel on the dropdownitem. It doesn't seem to work. I have tried textcolor, backgroundcolor, shadowcolor.

No effect.

Kind regards
W

Changing DropDownItem textLabel stuff not doing anything

Is there a reloadView() but for DropDownItem modifications?

I have the following:

let font = UIFont.init(name: "Avenir Next Medium", size: 15.0)
var items = [IGLDropDownItem]()
for type in options {
            let item = IGLDropDownItem()
            item.textLabel.font = font
            item.textLabel.textAlignment = .Center
            item.showBackgroundShadow = false
            item.text = type
            items.append(item)
}
dropdown.dropDownItems = items
dropdown.menuText = menuText
dropdown.type = .Normal
dropdown.menuButton.textLabel.font = font
dropdown.menuButton.textLabel.textAlignment = .Center
dropdown.menuButton.showBackgroundShadow = false
dropdown.reloadView()
self.view.addSubview(dropdown)
self.view.bringSubviewToFront(dropdown)

For my menuButton, the textLabel style is changing properly, but for the items themselves, the textLabel style is not changing at all. Am I missing something?

I also tried dropdown.reloadView() after self.view.addSubview(dropdown)

Use it with it UIbarButtonItem

Hello, I need to know how to implement this Library with UIbarButtonItem ?
I've tried to add the dropDownMenu button to the navigationItems but this make my app crash :

[IGLDropDownMenu _setOwningNavigationItem:]: unrecognized selector sent to instance

Great component! Scrolling?

Great component! Very well done!
I was wondering if you plan to implement some kind of scrolling in case you have more items than the screen fits?

storyboard custom menu button

When creating a IGLDropDownMenu via storyboards the constructor - (instancetype)initWithCoder:(NSCoder *)aDecoder will be used. that's why it is not possible to init your menu button with a custom view.
my quickfix was to remove the readonly property of @property (nonatomic, strong) IGLDropDownItem *menuButton;.
then i could set my custom menu button like this:

CustomDropDownItemView* customViewMenuButton = [[[NSBundle mainBundle] loadNibNamed:@"CustomDropDownItemView" owner:self options:nil] objectAtIndex:0];
customViewMenuButton.centeredImage.image = [UIImage imageNamed:@"ic_more_blue_36px"];
IGLDropDownItem* menuButton = [[IGLDropDownItem alloc] initWithCustomView:customViewMenuButton];

self.buttonDropDownMenu.menuButton = menuButton;

i don't know if this is correct in your opinion, but for me it worked. maybe there is another solution?

My own menu button

Is there some way to have my own UIView/UIButton as the menu button, and when it is selected, have the dropdown come down?

If anyone think it should re-write to a swift version, please leave a comment in this issue.

If anyone think it should re-write to a swift version, please leave a comment to tell me.
If this implement in swift, there are two plan:

  1. Just a swift version, no api or struct change, will work fine in your project to replace the objective-c version.
  2. A total new swift version with struct re-write and api change, can implement most of(not all) the old functions and some new effect. But maybe more change for replace the objective-c version.

Which one you prefer?

open menu upward?

Hi,
is it possible to open menu from bottom to up?
it would be great if there is a property for it.

Crash: IGLDropDownItem.h

Can you please make the delegate: @property (nonatomic, **weak**) id<IGLDropDownMenuDelegate> delegate;

My app crashes when the menu is currently open but I dealloc the viewcontroller which is also the delegate.

Currently I have to manually set the delegate to nil in the viewcontroller's dealloc function

Add UITapGesture to close menu

I've been trying to figure out how to close the menu when user taps somewhere on the screen. When users don't pick an option, or try to type something in a textField, I want to close the menu to keep the UI clean. How can I achieve this?

Unable to set width of IGLDropDownMenuItem

I am using autolayouts and trying to set the width of IGLDropDownMenu by

[self.dropdownMenu setFrame:CGRect(0,50,250, 35);

However the menu item doesn't seem to expand. I added background to dropdownmenu for debugging and it shows that initially, dropdownmenu is of the right size but the menu item doesn't expand.
And on tap, the DropDownMenu width is also resized to menu item width.

How do I set width for menuItem? or ensure that the menuItem takes all the space for in dropdownmenu

unable to scroll the menuitem

When the menu item is more than 12, then it is not possible to scroll.
There is no scrolling functionality support in order to view remaining items.

Dropdown hides behind the dropdown below it

I have two drop downs the second one is right below the firs one. When I open the first drop down it's expanded view hides behind the drop down below it. Please suggest a possible solution.

multiple IGLDropDownMenu

i tried to set multiple IGLDropDownMenu but when i expand first one second menu covers menu item of first dropdown menu.

can we have some suggestion from your side.

thanks for very clean and neat example.

Limited to one per view?

I only seem to be able to instantiate 1 IGLDropDownMenu per view, otherwise only the last added IGLDropDownMenu works

items problems

how to display item's text(what I want to show),text is long or short .IGLDropDownItem how to auto adjust height?

Can not using autolayout

I try to adding dropdown menu in UIScrollView. this can not be active by touch, only long touch.
And It can not be autolayout in my view.

updating cocoapods

i've found your lib and added it to my project via cocoapods:
https://cocoapods.org/?q=IGLDrop

unfortunatly there is the storyboard support missing. i've seen you did some change 2 hours ago. when you have finished them, can you please make an update to cocoapods? thanks a lot!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.