-
Notifications
You must be signed in to change notification settings - Fork 814
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
…xt (#776)
- Loading branch information
1 parent
b9936a2
commit 677aa53
Showing
3 changed files
with
250 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
app/src/main/java/swati4star/createpdf/util/AddTextEnhancementOptionsUtils.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
package swati4star.createpdf.util; | ||
|
||
import android.content.Context; | ||
|
||
import com.itextpdf.text.Font; | ||
|
||
import java.util.ArrayList; | ||
|
||
import swati4star.createpdf.R; | ||
import swati4star.createpdf.model.EnhancementOptionsEntity; | ||
|
||
public class AddTextEnhancementOptionsUtils { | ||
|
||
public static ArrayList<EnhancementOptionsEntity> getEnhancementOptions(Context context, | ||
String fontTitle, | ||
Font.FontFamily fontFamily) { | ||
ArrayList<EnhancementOptionsEntity> options = new ArrayList<>(); | ||
|
||
options.add(new EnhancementOptionsEntity( | ||
context.getResources().getDrawable(R.drawable.ic_font_black_24dp), | ||
fontTitle)); | ||
options.add(new EnhancementOptionsEntity( | ||
context, R.drawable.ic_font_family_24dp, | ||
String.format(context.getString(R.string.default_font_family_text), fontFamily.name()))); | ||
return options; | ||
} | ||
} |
Oops, something went wrong.