Skip to content

Commit c9d3c90

Browse files
okatrych-nordzebadge-gdg
authored andcommitted
Add GDG logo
1 parent 38552bc commit c9d3c90

2 files changed

Lines changed: 57 additions & 0 deletions

File tree

  • app/src/main
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
package de.berlindroid.zepatch.patchable
2+
3+
import androidx.compose.foundation.Image
4+
import androidx.compose.runtime.Composable
5+
import androidx.compose.ui.graphics.ImageBitmap
6+
import androidx.compose.ui.res.painterResource
7+
import androidx.compose.ui.tooling.preview.Preview
8+
import de.berlindroid.zepatch.R
9+
import de.berlindroid.zepatch.annotations.Patch
10+
import de.berlindroid.zepatch.ui.SafeArea
11+
12+
@Patch("GDGLogo")
13+
@Composable
14+
@Preview
15+
fun GDGLogo(
16+
shouldCapture: Boolean = false,
17+
onBitmap: (ImageBitmap) -> Unit = {},
18+
) {
19+
SafeArea(
20+
shouldCapture = shouldCapture,
21+
onBitmap = onBitmap,
22+
) {
23+
Image(
24+
painter = painterResource(R.drawable.gdg),
25+
contentDescription = null
26+
)
27+
}
28+
}

app/src/main/res/drawable/gdg.xml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<vector xmlns:android="http://schemas.android.com/apk/res/android"
2+
android:width="300dp"
3+
android:height="200dp"
4+
android:viewportWidth="300"
5+
android:viewportHeight="200">
6+
<path
7+
android:pathData="M23,0L277,0A23,23 0,0 1,300 23L300,177A23,23 0,0 1,277 200L23,200A23,23 0,0 1,0 177L0,23A23,23 0,0 1,23 0z"
8+
android:fillColor="#ffffff"/>
9+
<path
10+
android:pathData="M29.48,76.26L91.29,32.98A28.88,28.88 100,0 1,131.52 40.07L131.52,40.07A28.88,28.88 100,0 1,124.42 80.3L62.62,123.58A28.88,28.88 100,0 1,22.39 116.49L22.39,116.49A28.88,28.88 100,0 1,29.48 76.26z"
11+
android:strokeWidth="6"
12+
android:fillColor="#E94436"
13+
android:strokeColor="#fff"/>
14+
<path
15+
android:pathData="M176.48,119.26L238.29,75.98A28.88,28.88 100,0 1,278.52 83.07L278.52,83.07A28.88,28.88 100,0 1,271.42 123.3L209.62,166.58A28.88,28.88 100,0 1,169.39 159.49L169.39,159.49A28.88,28.88 100,0 1,176.48 119.26z"
16+
android:strokeWidth="6"
17+
android:fillColor="#F8AB00"
18+
android:strokeColor="#fff"/>
19+
<path
20+
android:pathData="M63.13,76.38L124.18,120.73A28.88,28.88 81,0 1,130.57 161.07L130.57,161.07A28.88,28.88 81,0 1,90.22 167.46L29.18,123.11A28.88,28.88 81,0 1,22.79 82.77L22.79,82.77A28.88,28.88 81,0 1,63.13 76.38z"
21+
android:strokeWidth="6"
22+
android:fillColor="#4286F4"
23+
android:strokeColor="#fff"/>
24+
<path
25+
android:pathData="M210.75,32.79L271.79,77.14A28.88,28.88 81,0 1,278.18 117.48L278.18,117.48A28.88,28.88 81,0 1,237.84 123.87L176.79,79.52A28.88,28.88 81,0 1,170.4 39.18L170.4,39.18A28.88,28.88 81,0 1,210.75 32.79z"
26+
android:strokeWidth="6"
27+
android:fillColor="#34A854"
28+
android:strokeColor="#fff"/>
29+
</vector>

0 commit comments

Comments
 (0)