textDrawable #136
No reviewers
Labels
No Label
Difficulty - Beginner friendly
Difficulty = Easy
Difficulty = Hard
Difficulty = Medium
Priority = CRITICAL
Priority = High
Priority = Low
Priority = Normal
Priority = Some day
Status - Fixed somewhere else
Status - No details provided
Status = Can't fix
Status = Duplicate
Status = Help wanted
Status = Invalid
Status = Need more details
Status = Taken
Status = Wontfix
Type - Selfoss works like this
Type = Bug
Type = Chore
Type = Enhancement
Type = Feature
Type = Question
Type = SELFOSS API ISSUE
Type = Tools
Type = UX/Design
Up For Grabs
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Louvorg/ReaderForSelfoss-multiplatform#136
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "davidoskky/ReaderForSelfoss-multiplatform:textDrawable"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Types of changes
This closes issue #120
Removed the dependency
com.amulyakhare.textdrawable
and slightly simplified the logic required to set circular images.Just a little cleaning, and this can be merged.
@ -91,3 +83,1 @@
.round()
.build(itm.title.getHtmlDecoded().toTextDrawableString(), color)
binding.sourceImage.setImageDrawable(drawable)
binding.sourceImage.setBackgroundAndText(itm.title.getHtmlDecoded(), itm.title.getHtmlDecoded().toTextDrawableString())
You could call
setBackgroundAndText
with a single parameter, and calltoTextDrawableString
inside.Also, here, there is an issue, it should be
itm.sourcetitle
that should be used.@ -65,3 +55,1 @@
.build(itm.title.getHtmlDecoded().toTextDrawableString(), color)
binding.itemImage.setImageDrawable(drawable)
binding.itemImage.setBackgroundAndText(itm.title.getHtmlDecoded(), itm.title.getHtmlDecoded().toTextDrawableString())
Same as before:
@ -0,0 +20,4 @@
val imageView: ShapeableImageView
val textView: TextView
private val colorScheme = listOf(
Why introduce a new way to handle colors, instead of using the color generator that was used previously ?
The color generator was provided by the library we're removing. I simply copied the relevant part of the code from there.
ea6261c975
to10ab67d071
Alright, this should do.