Skip to content
This repository has been archived by the owner on Jul 20, 2023. It is now read-only.

Add shadow to sidemenu #98

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

MaksymDyomin
Copy link

  • Add shadow to sidemenu
  • Make sidemenu icon size configurable

- Make sidemenu icon size configurable
@teodorpatras
Copy link
Owner

Hi, thanks for the PR. Have you seen the already implemented function setSideShadow?

@MaksymDyomin
Copy link
Author

Hi,
Yes I have seen function setSideShadow. It adds shadow from central panel to side panel. Screenshot is here: https://github.com/MaksymDyomin/SideMenuController/blob/master/screenshots/SideMenuControllerShadow1.png

And it works when side panel is under center panel. For using this function SideMenuController should be configured as following:
SideMenuController.preferences.drawing.sidePanelPosition = .underCenterPanelLeft
SideMenuController.preferences.drawing.centerPanelShadow = true

My pull request adds possibility to configure SideMenuController in different way:
SideMenuController.preferences.drawing.sidePanelPosition = .overCenterPanelLeft
SideMenuController.preferences.drawing.sidePanelShadow = true
This configuration will work if side panel will be over center panel. And shadow will be dropped from side panel to center panel.
Screenshot is here: https://github.com/MaksymDyomin/SideMenuController/blob/master/screenshots/SideMenuControllerShadow2.png

@gulzatique
Copy link

is there a way to change icon size? thanks

@MaksymDyomin
Copy link
Author

Yes, there is.
You can change hamburger icon size:
SideMenuController.preferences.drawing.menuButtonSize = CGSize(width: 18, height: 12)

@gulzatique
Copy link

@MaksymDyomin it says it has no member menuButtonSize

@MaksymDyomin
Copy link
Author

@gulzatique please note that this PR have not been merged. Are you sure you using my fork and branch sidemenu-shadow ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants