Home - OneUIProject/OneUI-Design-Library GitHub Wiki

⚠️ This library is deprecated and will no longer be updated. Check the new Samsung Experience Support Library. ⚠️

Documentation

Welcome to the OneUI Design Library documentation. In this wiki page, you will find all the infos regarding the library and how to use all its components. Do not mind to contact us in case you need any clarification, we will update the documentation if needed.

Samsung's OneUI apps are created by using an heavily modified version of Google's Jetpack and Material Components libraries, internally named "sesl-appcompat" (Sesl stands for Samsung Experience Software Library; iirc). Those modifications include a different styling of the UI, hover/S Pen support, new features and much more. The intent of this library is to make those Samsung UX elements available to everyone for study, modding or whatever feels right for you. Any form of contribution, suggestions, bug report or feature request will be welcome.

In general, most of the views are styled automatically when you apply the theme in AndroidManifest.xml, the usage of the custom views in the library however is needed to achieve the best results. If you're building apps specifically for Samsung devices, also check this out.

Themes

OneUI 4

  • Main: android:theme="@style/OneUITheme"
  • Splash: android:theme="@style/OneUISplashTheme"
  • About: android:theme="@style/OneUIAboutTheme"

OneUI 3

  • Main: android:theme="@style/OneUI3Theme"
  • Splash: android:theme="@style/OneUI3SplashTheme"
  • About: android:theme="@style/OneUI3AboutTheme"

To change the theme color (statically and/or dynamically) see ThemeUtil.


Layouts

Views

Widgets

Popups

Others

For further customization or if you need something which isn't implemented in the custom views yet (I can't think of all possible uses), you can always access the views inside it with findViewById(int id) and change them directly. For the Ids please refer to the source code.

Issues

Proguard

If you encounter problems with Proguard (missing classes), see this Issue by AlirezaIvaz.

Preview render problem

Some custom views might not render in the preview, because this library is using a font (sec-roboto-light), which Android Studio (and other IDEs probably too) don't know. To temporarily bypass this problem you can simply add

<string name="sesl_font_family_regular">sans-serif</string>

to your strings.xml. But don't forget to remove it afterwards for your release. Thanks to roynatech2544, for reporting this issue.

Samsung framework flags

Even if the library is complete, there are still some UI elements that are enforced in system frameworks. If your app is intended for Samsung devices, we suggest you to enable them manually:

  1. AndroidManifest.xml flag (apply it under the application tag):
<application>
    <meta-data android:name="SamsungBasicInteraction" android:value="SEP10"/>
    ...
</application>

This will style:

  • Dialogs (Gravity.BOTTOM, already set in library)
  • android.widget.Switch (OneUI styled)
  • android.view.View (Vertical padding in Scrollbar)
  • DecorView (Bottom rounded corners for every activity)
  1. DeviceDefault theme: To enable this you need to manually decompile your app with apktool; in the following files:
res/values/styles.xml
res/values-v25/styles.xml

Replace the parent Theme.Material theme in Platform.V21.AppCompat and Platform.V25.AppCompat with Theme.DeviceDefault.

This will style android.* views but also enable:

  • OneUI EdgeEffect style
  • PopupWindow clipToOutline (already set in library)
  • OneUI EditText Action mode

Changelog

2.4.0
  • time, date, number pickers
  • theme dynamic drawables (oui3/4)
  • icons++
  • improvements & bug/crash
2.3.0
  • Major updates to the following classes:
    • CoordinatorLayout/AppBar/CollapsingToolbar
    • Preferences
    • RecyclerView
    • TabLayout
    • ViewPager
  • Updated Seekbar & Progressbar
  • Added IndexScrollView
  • Added TipPopup
  • Added ViewPager2
  • Added OneUI 4 Dialogs
  • Reworked ToolbarLayout & friends
  • Reworked ColorPickerDialogs
  • Reworked folders hierarchy (check the wiki)
  • Fixed OUI4 Progress animation
  • Minor fixes
2.2.1
  • OneUI4++ (views, colors, fonts, themes)
  • PopupMenu improvements
  • fixes & minor changes
2.2.0
  • OneUI4++ (huge thanks to BlackMesa123)
    • AppBar/Toolbar
    • Edge effect
    • TabLayout/BottomNavigationView
    • SwipeRefreshLayout
    • EditText
    • and more...
  • ToolbarLayout & PopupMenu/Menu improvements
  • icons++ (OneUI4)
  • fixes & minor changes
2.1.1
  • ThemeColor > ThemeUtil
  • dark mode fix (ThemeUtil)
  • Button/AboutPage improvements
  • preference notifyChanged()
  • ToolbarLayout getToolbarMenuItemView()
  • OneUI4 Switch
  • minor changes
2.1.0
  • seekbar vertical and improved
  • toolbar improvements
    • SearchMode
    • SelectMode
    • custom Title & collapsed subtitle
    • toolbar menu
  • swipeRefreshLayout
  • PopupMenu improvements
  • some OneUI 4 stuff
  • crash fixes
  • icons++
2.0.1
  • fixed:
    • scroll behavior on clickable views
    • aboutpage button font and ripple
    • popupmenu going beyond screen
    • drawerLayout back click closes drawer
    • crash on small screens/dpi
  • icons++
  • Spinner
  • BottomNavigationView improvements
2.0.0
  • contributions from BlackMesa123:
    • AppBarLayout (& friends)
    • Preferences
    • Classic Color Picker
    • Dialogs
    • Tooltip
    • TabLayout
    • BottomNavigationView
    • Layouts rework
    • NestedScrollView, RecyclerView, Round Layouts
    • and much more (most of the stuff in this release)
  • a lot of fixes and improvements
  • support for api 21+
  • Snackbar & PopupMenu
  • more icons
  • now available on mavencentral
1.3.0
  • renamed library
  • getView methode added
  • splash screen display size fix
  • minor changes
1.2.2
  • Scrollbar
  • AboutPage
  • RelatedCard
  • corner fix
  • language update
  • customizable splash animation
  • expanded attribute for toolbar
  • fixed landscape toolbar height
  • improved orientation switching
  • button text fix
  • status & navigation bar dim on drawer slide
  • added changelog to readme
1.2.1
  • landscape support
  • tablet support
  • dex support
  • expandable attribute for toolbar
  • toolbar subtitle color
  • added Header style
1.2.0
  • colorPicker
  • color Changer
  • readme finished
  • much more icons
  • rtl support
  • translated to 90 languages
1.1.3 - 1.0.0
  • initial release/publish
  • most of the stuff (I don't remember anymore...)

⚠️ **GitHub.com Fallback** ⚠️