How to implemention PhotoEditor?
See original GitHub issueI have some difficulty understanding, why does not show me anything? What have I missed?
I add gradle
implementation 'ja.burhanrashid52:photoeditor:0.3.3'
layout.xml
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/black"
tools:context=".MainActivity">
<ja.burhanrashid52.photoeditor.PhotoEditorView
android:id="@+id/photoEditorView"
android:layout_width="wrap_content"
android:layout_height="384dp"
app:photo_src="@drawable/ic_stat_name" />
</android.support.constraint.ConstraintLayout>
MainActivity.java:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
PhotoEditorView mPhotoEditorView = findViewById(R.id.photoEditorView);
mPhotoEditorView.getSource().setImageResource(R.drawable.ic_stat_name);
Typeface mTextRobotoTf = ResourcesCompat.getFont(this, R.font.roboto_medium);
Typeface mEmojiTypeFace = Typeface.createFromAsset(getAssets(), "fonts/emojione-android.ttf");
PhotoEditor mPhotoEditor = new PhotoEditor.Builder(this, mPhotoEditorView)
.setPinchTextScalable(true)
.setDefaultTextTypeface(mTextRobotoTf)
.setDefaultEmojiTypeface(mEmojiTypeFace)
.build();
}
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:9 (4 by maintainers)
Top Results From Across the Web
Photo Editor Project Implementation (Helpful suggestions)
Photo Editor Project Implementation (Helpful suggestions) · Calculate its position in the original image using an appropriate scale and offset. · Use the...
Read more >Full Guide on How to Make a Photo Editing App - Cleveroad
How to Make a Photo Editing App · Step 1. Research the marker and look through your competitors' solutions. · Step 2. Hire...
Read more >Photo Editing App Development [Main steps] - Yellow Systems
How to make your own photo editing app? ... Creating a new photo editor isn't an easy task to complete. It consists of...
Read more >How to Make Your Own Photo Editing App like PicsArt
Photo Editing Block · # 1: Upload a photo · # 2: Basic photo editing · # 3: Crop, resize, rotate ✂️...
Read more >Photo Editor - Code Samples - Microsoft Learn
Photo Editor shows you how to retrieve photos from the Pictures library, and then edit the selected image with assorted photo effects. In...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Do I have to do everything XML or just one by one?
I have not figured out how to make it work till now. Lets assume I want similar Layout of the editor like the one with Ned Stark. So how my xml need to look like? Like this or this. Is there any sample app?