Skip to content
This repository was archived by the owner on Aug 22, 2024. It is now read-only.

Commit 12112a6

Browse files
committed
[UPDATE] [#22] Added docs and renamed resources properly.
1 parent 02466d8 commit 12112a6

File tree

6 files changed

+8
-8
lines changed

6 files changed

+8
-8
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ A demo application for Android `ConstraintLayout` with various usage with sample
1919
* [ ] Vertical Axis: top, bottom sides and text baseline
2020
- [ ] Margins
2121
- [x] Centering positioning and bias
22-
- [ ] Circular positioning _(Added in 1.1)_
22+
- [x] Circular positioning _(Added in 1.1)_
2323
- [ ] Visibility behavior
2424
- [ ] Dimension constraints
2525
* [ ] Ratio
@@ -49,4 +49,4 @@ These are the **my** objectives for this demo application.
4949
## Preview
5050
Here is a snapshot of current progress _(This will be updated from time to time)_.
5151

52-
![Browse Layout Variances](https://user-images.githubusercontent.com/99822/39676220-f20ef5c6-5134-11e8-9430-08f90b5fe5fb.png) ![Show Layout Screen](https://user-images.githubusercontent.com/99822/39676265-a0bb1f28-5135-11e8-8c34-014cef844e97.png)
52+
![Browse Layout Variances](https://user-images.githubusercontent.com/99822/39677044-d235942c-5142-11e8-972d-bb0885f87384.png) ![Show Layout Screen](https://user-images.githubusercontent.com/99822/39676265-a0bb1f28-5135-11e8-8c34-014cef844e97.png)

app/src/main/java/com/hossainkhan/android/demo/data/LayoutDataStore.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,17 +29,17 @@ class LayoutDataStore @Inject constructor(
2929
val supportedLayoutInfos = listOf(
3030
LayoutInformation(
3131
layoutResourceId = R.layout.preview_positioning_top_left,
32-
thumbnailResourceId = R.drawable.ic_positioning_top_left,
32+
thumbnailResourceId = R.drawable.thumb_positioning_top_left,
3333
title = "Positioning: Top Left",
3434
description = "Top left using constraints."),
3535
LayoutInformation(
3636
layoutResourceId = R.layout.preview_positioning_centered,
37-
thumbnailResourceId = R.drawable.ic_positioning_center,
37+
thumbnailResourceId = R.drawable.thumb_positioning_center,
3838
title = "Positioning: Centered",
3939
description = "Centered view using constraints on top-bottom and left-right."),
4040
LayoutInformation(
4141
layoutResourceId = R.layout.preview_positioning_circular,
42-
thumbnailResourceId = R.drawable.ic_positioning_circular,
42+
thumbnailResourceId = R.drawable.thumb_positioning_circular,
4343
title = "Positioning: Circular",
4444
description = "You can constrain a widget center relative to another widget center, at an angle and a distance. This allows you to position a widget on a circle." +
4545
"\n\n" +
File renamed without changes.

app/src/main/res/drawable/ic_positioning_circular.xml renamed to app/src/main/res/drawable/thumb_positioning_circular.xml

File renamed without changes.

app/src/main/res/drawable/ic_positioning_top_left.xml renamed to app/src/main/res/drawable/thumb_positioning_top_left.xml

File renamed without changes.

app/src/main/res/layout/preview_positioning_circular.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525

2626

2727
<!--
28-
First setup a centered view.
28+
First setup a centered view which will be used to place other textviews using circular angle.
2929
-->
3030
<View
3131
android:id="@+id/view_centered"
@@ -36,7 +36,7 @@
3636
app:layout_constraintTop_toTopOf="parent" />
3737

3838
<!--
39-
Text at 45 degree with radius 100dp
39+
Text at 45 degree with distance 100dp from centered box.
4040
-->
4141
<TextView
4242
style="@style/SimpleInfoTextView"
@@ -47,7 +47,7 @@
4747
tools:ignore="HardcodedText" />
4848

4949
<!--
50-
Text at 220 degree with radius 150dp
50+
Text at 220 degree with distance 150dp from centered box.
5151
-->
5252
<TextView
5353
style="@style/SimpleInfoTextView"

0 commit comments

Comments
 (0)