I find it almost impossible to believe this, and I have probably misunderstood something…
I’m making a educational app for learning foreign words and I desperately need the ability to NOT automatically capitalize the first entered letter in a text field. Is this not possible at all for iOS builds with Corona?
But it only has 51 votes on it. While it seems like it should be a no-brainer, we still have to prioritize it with all the other work we have going. We only have limited engineering hours and you (the community) have a long list of requests. Encourage more people to vote for this.
I’m a software developer in a larger organisation, we also have a fairly large support/request queue. From France alone it’s above 22000 now…
Point is, I’m familiar with how a request queue works. We have an in-house practice, however: if it’s an obvious thing (which will benefit many customers) and if it’s easy/fast to implement, we simply just do it. Maybe it’s a stupid thing to, but we’re doing quite well so it’s at least not a company destroying practice…
Not to mention the feature request was back in 2013.
I have a simple system for feature requests in my games… I have 3 folders in Outlook (per game) called “easy”, “medium” and “hard” and that roughly translates into “hours”, “days” and “weeks”.
The problem with the current “get x votes before we look at it” systems means that often easy wins like this just get ignored.
I’m asking engineering about it. It can’t be implemented in a cross-platform way. If we did, it would be iOS only. I believe as a community, you would likely be happy with this being an iOS-only feature.
They said, there are cross-platform issues with it. I said the community would appreciate it even if it was iOS only. Right now Engineering’s workload is full with must-do projects and this is something I’ll need to bring back up at some point in the future.
local keyboardEvents = require "plugin.keyboardEvents" -- Call this for text fields keyboardEvents.setTextFieldAutocapitalizationType("None") -- Call this for text boxes keyboardEvents.setTextBoxAutocapitalizationType("None")
Both methods takes one of the following options: “None”, “Words”, “Sentences” or “AllCharacters”
The autocapitalization type will be set on all instances of text boxes or text fields in your app.
If you need different autocapitalization types on different text fields you can switch the type in the began phase of the individual textInputListeners.
I guess if things were working as supposed to, the keyboard would show all lowercase letters?
What I’ve done is this:
main.lua:
local keyboardEvents = require "plugin.keyboardEvents" -- Turn off auto capitalization for text fields and text boxes (only for iOS) keyboardEvents.init() keyboardEvents.setTextFieldAutocapitalizationType("None") keyboardEvents.setTextBoxAutocapitalizationType("None") keyboardEvents.setAutocorrectionType("UITextAutocorrectionTypeNo") keyboardEvents.setSpellCheckingType("UITextAutocorrectionTypeNo")
I added setAutocorrectionType() and setSpellCheckingType() for good measure.
I also called init() first.
I also added the following line under the plugins section in build.settings:
You need to do the calls after creating your text fields/boxes. Something like this:
local textField = native.newTextField( 150, 50, 180, 30 ) keyboardEvents.setTextFieldAutocapitalizationType("None")
Or if you need to change the autocapitalization type on different text fields you can set it in the began phase of the listener like this:
local function textListener( event ) if ( event.phase == "began" ) then keyboardEvents.setTextFieldAutocapitalizationType("None") end end local textField = native.newTextField( 150, 50, 180, 30 ) textField:addEventListener( "userInput", textListener )