C
C
Chvalov2015-11-05 00:31:26
Android
Chvalov, 2015-11-05 00:31:26

How to make a 9-patch of such a picture?

How to correctly create a 9Patch of waters of such a picture
UPD : Do not look at the fact that it is lighter on top and darker below, the main thing for me is to understand how to repeat such lines so that it turns out beautifully, here is the picture I need
UPD 2: If for the web I made something like this picture size 3 by 3 c1712a8bed2a44368c49f36237fd3eff.png
and repeated it, then how can I use it in an android project? and specify it as a background?
9Patch it only stretches, but I need to repeat it
line_slanting_dark_background_surface_te
So that the output has a small and stretchable picture, or tell me how to do the same on pure XML

Answer the question

In order to leave comments, you need to log in

1 answer(s)
C
Chvalov, 2015-11-05
@Chvalov

Sori, I figured out what the problem is:
Create a background.xml in the drawable folder
with the following content:

<?xml version="1.0" encoding="utf-8"?>
<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
  android:src="@drawable/bg_pic" 
  android:tileMode="repeat" />
After that, on the element where you need such a background
:

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question