-
-
Notifications
You must be signed in to change notification settings - Fork 7
Support custom sized barcodes with transparent background #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,7 +28,7 @@ enum class BarcodeType(private val barcodeFormat: BarcodeFormat) { | |
| for (y in 0 until height) { | ||
| val offset = y * width | ||
| for (x in 0 until width) { | ||
| pixels[offset + x] = if (get(x, y)) android.graphics.Color.BLACK else android.graphics.Color.WHITE | ||
| pixels[offset + x] = if (get(x, y)) android.graphics.Color.BLACK else android.graphics.Color.TRANSPARENT | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 👍🏻 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It would also be nice to have the main color being passed from the barcode view and not be black all the time :) |
||
| } | ||
| } | ||
| setPixels(pixels, 0, width, 0, 0, width, height) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not remove this until v2 please