change barcode scanner app locales when starting intent

75 views
Skip to first unread message

Florin Onciu

unread,
Sep 21, 2015, 7:49:27 AM9/21/15
to zxing
Hi, and thanks for the library/app. I am using Barcode Scanner app via Intents and I have a few questions.

1. Is it possible to change the barcode scanner app language via intents? My use case would be that in my app, there are different users that use the app in different languages, independent of default device language. I want to start the scanner app in different languages but I am not sure it's possible, or how can I do that.


2. I am trying to adjust some parameters via IntentIntegrator but where can I find these options that can be tweaked via intent?

example:
IntentIntegrator scanIntegrator = new IntentIntegrator(thisActivity);
// add more options
scanIntegrator.addExtra(key, value);


Lastly, it would be nice to be able to use Barcode Scanner app fully via intents (including enabling/disabling) features when running the app.

Lachezar Dobrev

unread,
Sep 23, 2015, 4:14:24 AM9/23/15
to Florin Onciu, zxing
  I've had to deal with non-device language before, and it's a nuisance (euphemism). Especially if the locale that you're asking for is not available on the device.

  1. No, AFAIK.

  2. com.google.zxing.client.android.Intents.Scan
  https://github.com/zxing/zxing/blob/master/android/src/com/google/zxing/client/android/Intents.java
  This class contains the constants and explains how to use them.

  The Intent Integrator is an easy way to start, and includes a check whether the Bar-Code Scanner has been installed. Other than that you're free to call the Intents.Scan.ACTION intent and customise a variety of behavioural parameters: from bar-code mode and type to the text to be displayed when starting the scan and time to wait after the scan. The Intent Integrator does have an addExtra(String, Object), which allows you to do the same with it.



--
You received this message because you are subscribed to the Google Groups "zxing" group.
To unsubscribe from this group and stop receiving emails from it, send an email to zxing+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages