It is impossible to add a custom code style in Android Studio that is stored in the project repository. So change style to something that's easy to use in practice now rather than later.
This uses intents, not a built-in scanner, so a seperate app is required (eg "Barcode Scanner").