Skip to content

Commit

Permalink
Shrank HTML button and tightened its margins
Browse files Browse the repository at this point in the history
- Renamed and kept the previous margin dimens, to be used for the tablet version
- Some style cleanup
  • Loading branch information
aforcier committed Apr 23, 2015
1 parent baa00c8 commit 0d2a713
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 12 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 9 additions & 9 deletions WordPressEditor/src/main/res/layout/fragment_editor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@
android:layout_width="fill_parent"
android:layout_height="@dimen/format_bar_height"
android:layout_gravity="bottom"
android:layout_marginLeft="@dimen/format_bar_side_margin"
android:layout_marginRight="@dimen/format_bar_side_margin"
android:layout_marginLeft="@dimen/format_bar_left_margin"
android:layout_marginRight="@dimen/format_bar_right_margin"
android:orientation="horizontal">

<HorizontalScrollView
Expand All @@ -44,49 +44,49 @@

<ToggleButton
android:id="@+id/format_bar_button_media"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_media_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_bold"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_bold_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_italic"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_italic_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_quote"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_quote_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_ul"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_ul_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_ol"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_ol_selector"/>

<ToggleButton
android:id="@+id/format_bar_button_link"
style="@style/FormatBarButton"
style="@style/FormatBarScrollViewButton"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:background="@drawable/format_bar_button_link_selector"/>
Expand Down
9 changes: 7 additions & 2 deletions WordPressEditor/src/main/res/values/dimens.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen name="format_bar_height">40dp</dimen>
<dimen name="format_bar_side_margin">5dp</dimen>
<dimen name="format_bar_left_margin">5dp</dimen>
<dimen name="format_bar_right_margin">2dp</dimen>
<dimen name="format_bar_button_right_margin">4dp</dimen>
<dimen name="format_bar_html_button_left_margin">9dp</dimen>
<dimen name="format_bar_html_button_left_margin">3dp</dimen>

<dimen name="format_bar_left_margin_tablet">5dp</dimen>
<dimen name="format_bar_right_margin_tablet">9dp</dimen>
<dimen name="format_bar_html_button_left_margin_tablet">9dp</dimen>

<dimen name="format_bar_horizontal_divider_height">1dp</dimen>
<dimen name="format_bar_vertical_divider_width">0.6dp</dimen>
Expand Down
5 changes: 4 additions & 1 deletion WordPressEditor/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@
<style name="FormatBarButton">
<item name="android:minWidth">@dimen/format_bar_height</item>
<item name="android:minHeight">@dimen/format_bar_height</item>
<item name="android:layout_marginRight">@dimen/format_bar_button_right_margin</item>
<item name="android:textOn">""</item>
<item name="android:textOff">""</item>
</style>

<style name="FormatBarScrollViewButton" parent="FormatBarButton">
<item name="android:layout_marginRight">@dimen/format_bar_button_right_margin</item>
</style>

<style name="FormatBarHtmlButton" parent="FormatBarButton">
<item name="android:layout_marginLeft">@dimen/format_bar_html_button_left_margin</item>
</style>
Expand Down

0 comments on commit 0d2a713

Please sign in to comment.