Closed hewa-jalal closed 4 years ago
You want to have the drawer to be full width? or you don't want to have a DrawerLayout
at all and just use the list itself somewhere inside your application?
If you want the drawer to be full width, or a custom width consider to look into the following method: https://github.com/mikepenz/MaterialDrawer/blob/develop/library/src/main/java/com/mikepenz/materialdrawer/DrawerBuilder.kt#L545-L580 (Note this overwrites the optimal drawer width as specified in the guidelines)
If you want to embed the drawer inside the activity (and have no DrawerLayout
) then look at the following:
https://github.com/mikepenz/MaterialDrawer/blob/develop/app/src/main/java/com/mikepenz/materialdrawer/app/EmbeddedDrawerActivity.kt
(note this is no longer a drawer then)
Unfortunately, i know nothing about Kotlin code, is there available in Java?
The latest releases of this library are kotlin specific. you should really really consider looking into it.
Coming fresh from the KotlinConf in Copenhagen. and I must tell you it is the future :D and will open you many doors to new areas.
But beside some Kotlin advertisement :P...
v6.1.2 of the drawer (as noted in the README) also showcases on how to embed
the drawer inside the application (without having a drawer) just the list:
https://github.com/mikepenz/MaterialDrawer/blob/v6.1.2/app/src/main/java/com/mikepenz/materialdrawer/app/EmbeddedDrawerActivity.java
And well the code from the DrawerBuilder (the methods) are called the same :D
okay, got it, thank you for your help.
can i enlarge drawer item so they can be shown like a recycler view row ? now they look too small