52 lines
2.1 KiB
Markdown
52 lines
2.1 KiB
Markdown
# Encoding-with-zxing Android
|
|
Encoding with zxing (Qr code, PDF 417)
|
|
|
|
<img src="icon.png" align="right" />
|
|
# Encoding-with-zxing Android [](https://github.com/MelDiSooQi/Encoding-with-zxing)
|
|
> A curated list of encoding with zxing README
|
|
|
|
- [Berif](https://github.com/MelDiSooQi/Encoding-with-zxing) - Project logo. Clear description of what the project does. Build badges. Demo screenshot. Simple install and usage sections. Includes an examples section with common uses.
|
|
|
|
Elements in beautiful READMEs include, but not limited to: images, screenshots, GIFs, text formatting, etc.
|
|
|
|
##Add library dependency
|
|
|
|
First add encoding_zxing_lib in your project
|
|
Then :
|
|
|
|
compile project(path: ':encoding_zxing_lib')
|
|
|
|
##To generate encode of QrCode
|
|
|
|
Example -1
|
|
|
|
EncodingZxing.encodeToQrCode(text, size);
|
|
---------------------------------
|
|
EncodingZxing.encodeToQrCode("Encoding with zxing", 500));
|
|
---------------------------------
|
|
imageView.setImageBitmap(EncodingZxing.encodeToQrCode("Encoding with zxing", 500));
|
|
|
|
Example -2
|
|
|
|
EncodingZxing.encodeToQrCode(text,
|
|
width,
|
|
height,
|
|
dotColor,
|
|
backgroundColor);
|
|
---------------------------------
|
|
EncodingZxing.encodeToQrCode("Encoding with zxing",
|
|
400,
|
|
400,
|
|
Color.BLACK,
|
|
Color.WHITE);
|
|
|
|
##To generate encode of PDF417
|
|
|
|
Example -1
|
|
|
|
EncodingZxing.encodeToPDF417(text, size, dotColor, backgroundColor)
|
|
---------------------------------
|
|
imageView.setImageBitmap(EncodingZxing.encodeToPDF417(text, size, dotColor, backgroundColor));
|
|
---------------------------------
|
|
imageView.setImageBitmap(EncodingZxing.encodeToPDF417("Encoding with zxing", 500, Color.BLACK, Color.WHITE));
|