Skip to content

Commit

Permalink
More work on UI styles.
Browse files Browse the repository at this point in the history
  • Loading branch information
JanmanX committed Jun 14, 2017
1 parent 7ab8b21 commit 9801e8b
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 21 deletions.
2 changes: 1 addition & 1 deletion app/src/main/res/drawable/edit_text_style.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
android:shape="rectangle">
<stroke android:width="2dp"

android:color="#499bea"/>
android:color="#49a6ff"/>
<corners android:radius="2dp" />

</shape>
5 changes: 1 addition & 4 deletions app/src/main/res/drawable/edit_text_style_dark.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,7 @@
android:thickness="0dp"

android:shape="rectangle">
<stroke android:width="2dp"

android:color="#499bea"/>
<corners android:radius="2dp" />
<corners android:radius="2dp" />

<solid android:color="#cccccc"></solid>
</shape>
12 changes: 9 additions & 3 deletions app/src/main/res/layout/activity_encrypt.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,16 @@
android:hint="Password"
android:inputType="textPassword"
android:textColor="#000000"
android:textColorHint="#292929"/>
android:textColorHint="#292929"
/>
<EditText
android:id="@+id/editText1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minLines="5"
android:background="#afafaf"
android:gravity="top|center"
android:textColor="@color/colorPrimaryDark"
android:background="@drawable/edit_text_style"
/>

<LinearLayout
Expand Down Expand Up @@ -63,7 +66,10 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:minLines="5"
android:background="#afafaf"
android:textColor="@color/colorPrimaryDark"
android:background="@drawable/edit_text_style_dark"
android:enabled="false"
android:selectAllOnFocus="true"
/>


Expand Down
25 changes: 13 additions & 12 deletions app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<EditText
android:id="@+id/editText"
android:layout_width="362dp"
android:layout_height="218dp"
android:layout_height="250dp"
android:layout_marginEnd="8dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
Expand All @@ -20,33 +20,34 @@
android:ems="10"
android:gravity="top|center"
android:inputType="textMultiLine"
app:layout_constraintHorizontal_bias="0.484"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
tools:layout_editor_absoluteY="16dp"
tools:layout_editor_absoluteX="-50dp" />
android:layout_marginBottom="24dp"
app:layout_constraintBottom_toTopOf="@+id/editText3" />

<EditText
android:id="@+id/editText3"
android:layout_width="364dp"
android:layout_height="228dp"
android:layout_height="250dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="8dp"
android:background="@drawable/edit_text_style_dark"
android:ems="10"
android:enabled="false"
android:inputType="textMultiLine"
app:layout_constraintHorizontal_bias="0.483"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
android:enabled="false"
app:layout_constraintTop_toBottomOf="@+id/editText"
tools:layout_editor_absoluteX="19dp" />
android:layout_marginBottom="8dp"
app:layout_constraintBottom_toTopOf="@+id/buttonEncrypt" />

<Button
android:id="@+id/buttonEncrypt"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginLeft="8dp"
android:layout_marginBottom="16dp"
android:layout_marginLeft="16dp"
android:text="Encrypt"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent" />
Expand All @@ -55,10 +56,10 @@
android:id="@+id/button2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginBottom="10dp"
android:layout_marginBottom="16dp"
android:text="Decrypt"
app:layout_constraintBottom_toBottomOf="parent"
android:layout_marginRight="16dp"
android:layout_marginRight="25dp"
app:layout_constraintRight_toRightOf="parent" />

</android.support.constraint.ConstraintLayout>
2 changes: 1 addition & 1 deletion app/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<resources>

<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
Expand Down

0 comments on commit 9801e8b

Please sign in to comment.