Disable ActionBar RTL Direction

前端 未结 2 2098

Android 4.2 introduced RTL (BiDi) support, to start using it I just follow the instructions (android:supportsRtl attribute to the element in your manifest file and set it “true\

2条回答
  •  走了就别回头了
    2021-02-08 16:16

    i had the same problem , only that i have a slidingMenu (AKA navigation drawer), so it got even weirder (meaning you click on the top right "up" button and show the drawer on the left...).

    there are 2 possible solutions:

    1. by code , in each activity:

      if (VERSION.SDK_INT >= VERSION_CODES.JELLY_BEAN_MR1)
          getWindow().getDecorView().setLayoutDirection(View.LAYOUT_DIRECTION_LTR);
      
    2. by theme. edit your own customized theme, and add the correct line. example:

      
      
      
      

提交回复
热议问题