Search Unity

Advanced Input Field 2

Discussion in 'Assets and Asset Store' started by fennecx_development, Dec 25, 2020.

  1. Riken_rds

    Riken_rds

    Joined:
    Apr 4, 2017
    Posts:
    49
    thank you for your support.
    please check this and let me know it is possible to fix this ?
     
  2. fennecx_support

    fennecx_support

    Joined:
    Dec 28, 2020
    Posts:
    133
    The easiest way would to just make the inputfield RectTransform smaller horizontally or increase the horizontal padding of the TextArea child object:
    upload_2022-3-2_20-54-39.png
    I've tried to just flip the cursor when it gets cut out from the sides (to make it possible to select the cursor),
    but this still makes it difficult to select the first few characters when dragging the cursor.

    I've noticed that Whatsapp also just has some padding on the left and right side for text input.
     
  3. Riken_rds

    Riken_rds

    Joined:
    Apr 4, 2017
    Posts:
    49
    thank you for your support
    if i type message "hello how are you?" than cursor should only reach text but currently cursor goes more than text value.
    please see attach video so you can better understand and better idea to fix this issue.
    can we have set cursor start and end point with selection portion(blue selection part) ?
     

    Attached Files:

  4. Riken_rds

    Riken_rds

    Joined:
    Apr 4, 2017
    Posts:
    49
    i am trying to use Emoji but some time i am getting this error and app is Crash
    Error: UTF-16 to UTF-8 conversion failed because the input string is invalid
    Please check and let me if you found any issue
     

    Attached Files:

    • s40.PNG
      s40.PNG
      File size:
      126.5 KB
      Views:
      248
  5. Riken_rds

    Riken_rds

    Joined:
    Apr 4, 2017
    Posts:
    49
    please check this i am Re-fetching this issue only issue on when i type emoji otherwise working fine
     

    Attached Files:

    • s42.PNG
      s42.PNG
      File size:
      112.5 KB
      Views:
      252
    Last edited: Mar 4, 2022
  6. fennecx_support

    fennecx_support

    Joined:
    Dec 28, 2020
    Posts:
    133
    Could reproduce it, was a limitation of text bounds calculation in multiline mode (needs to be full width for line wrapping). I've implemented an extra variable to measure the max width of text contents themselves as a workaround for this.

    To fix install included patch package
     

    Attached Files:

  7. fennecx_support

    fennecx_support

    Joined:
    Dec 28, 2020
    Posts:
    133
    This is not a plugin error, see the class it's mentioning: UnityEngine.UI.InputfField:set_text(); That's the official Unity inputfield. Unity's own implementation probably can't handle complex strings.
     
  8. fennecx_support

    fennecx_support

    Joined:
    Dec 28, 2020
    Posts:
    133
    Not really sure what I should see here. Don't know how you are calculating the character count at the moment to display that "-1", but keep in mind that whitespace and newline characters are also counted as characters.
    You could copy the GetCharacterCount() method from EmojiCharacterLimitFilter.cs for your calculation/comparison or modify that method if you don't want to count whitespaces and/or newline characters.
     
  9. fennecx_support

    fennecx_support

    Joined:
    Dec 28, 2020
    Posts:
    133
    GENERAL NOTICE:
    I've decided to stop developing/supporting this plugin. I know this can be an inconvenience for the current users of the plugin, but the plugin will be opensourced soon. This way the current work on the plugin won't be lost and other developers can fork the repository and continue development.
    The reason for stopping development is mostly related to available development time. I've developed/supported this plugin for almost 5 years in my free time, but now it's time I want to focus on other projects.

    I hope you can respect my decision, although it might come as an inconvenience.

    Opensource repository:
    Github link
     
    Last edited: Mar 6, 2022
    PrisedRabbit likes this.
  10. jGate99

    jGate99

    Joined:
    Oct 22, 2013
    Posts:
    1,941
    I bought the plugin like few months ago and this news came up.
    Its disappointing because there is no alternate option available in the market, Now our app will take step back because of its absence :(
     
  11. unity_owRvJl36ZWJfJw

    unity_owRvJl36ZWJfJw

    Joined:
    Apr 21, 2020
    Posts:
    1
    Thank you for the awesome plugin.
    Is there a way to prevent the keyboard from closing when the "Done" or "send" button is pressed on Android?
     
  12. jmansa

    jmansa

    Joined:
    Apr 13, 2012
    Posts:
    75
    After installing the plugin I get this error: The type or namespace name 'TMProEmojiAsset' could not be found

    Any idea how to fix this?
     
  13. Yiming075

    Yiming075

    Joined:
    Mar 24, 2017
    Posts:
    33
    Can it work with UGUI without TextMeshPro? TextMeshPro is hard to use since it didn't support most of the language like Arial.ttf in UGUI :(
     
  14. Trall_lol

    Trall_lol

    Joined:
    Jul 3, 2019
    Posts:
    1
    i am getting error after importing your plugin. Tools does not appear for me to create my own emoticons. How can the problem be solved?
     

    Attached Files:

  15. TeamMEW

    TeamMEW

    Joined:
    Jan 8, 2016
    Posts:
    6
    Thanks for making a great plugin. This is my last hope.
    How do I prevent the keyboard from disappearing when I'm done typing?
     
    rihnesty likes this.
  16. DunanStar

    DunanStar

    Joined:
    Jun 23, 2016
    Posts:
    12
    Thank you for developing a great asset.

    I know that the support has been suspended, but I would appreciate your cooperation.

    I have to express in Unity that the word corresponding to the input field is highlighted in gray color when the predictive function is operated on the native keyboard of Android/iOS.
    For better understanding, I attached a screenshot of the keyboard's predictive function in the native app.

    Is it possible to make this function with the current asset?
    Otherwise, do you believe that this is feasible by modifying the native plug-in of the asset?

    Thanks..
    IMG_2970.PNG IMG_2971.PNG
     
    Last edited: Jul 26, 2022
  17. tiburon

    tiburon

    Joined:
    Oct 10, 2013
    Posts:
    28
    The solution to this is to uncheck "render outside safe area" in Player Settings.
     
  18. LexaMV

    LexaMV

    Joined:
    Feb 20, 2018
    Posts:
    28
    Hi all

    TouchScreenKeyboard.visible not work with you asset?
     
  19. nareshbishtasus

    nareshbishtasus

    Joined:
    Jun 11, 2018
    Posts:
    36
    Hi, is it possible to open native mobile input box above keyboard (just like normal input field does) Advanced input field? If yes please let me know. Thank you.

     
    Omid7L likes this.
  20. SachinGanesh

    SachinGanesh

    Joined:
    Jun 28, 2015
    Posts:
    20
    Hi,
    We are having an issue where keyboard types on multiple Inputfields at the same time. I have attached issue file

    Unity Version : 2020.3.34f1
    Platform : iOS

    Thanks
     

    Attached Files:

    sheralex1998 and CodeFluegel like this.
  21. elfasito

    elfasito

    Joined:
    Jul 4, 2017
    Posts:
    51
    Hi @realragnvaldr
    You manage to solve it?.
     
  22. Farshadfarzan368

    Farshadfarzan368

    Joined:
    Sep 10, 2022
    Posts:
    73
    Hello, can you optimize it for Farsi and Arabic, which are similar? It is not possible to edit the text. I have another request, I want to control the closing of the Android keyboard and close it only with the back key so that it is useful for chatting I need it badly and this Persian link supports it

    https://github.com/pnarimani/RTLTMPro
     
  23. Farshadfarzan368

    Farshadfarzan368

    Joined:
    Sep 10, 2022
    Posts:
    73
    Please add crate with RTL text mesh prro
    For support Farsi and Arabic
    Fix caret position in Arabic and Persian for edit text
    Download RTL text mesh pro :
    https://github.com/pnarimani/RTLTMPro
     
  24. Omid7L

    Omid7L

    Joined:
    Jun 10, 2018
    Posts:
    14
    Hi, thanks for this valuable and helpful asset.
    My issue is that the keyboard covered the input field and users can't see what is typed there. Is there any way to show entered text above the keyboard?
     
  25. Omid7L

    Omid7L

    Joined:
    Jun 10, 2018
    Posts:
    14
    Did you find any way to fix this?
     
  26. Damast

    Damast

    Joined:
    Apr 25, 2019
    Posts:
    13
    Hello everyone, I found this asset recently and it solves a lot of my problems but I don't know how to solve the following behavior:
    When exporting for Android, the canvas resizes when the mobile keyboard is opening. How can I get the standard behavior with no scrolling/resizing?
    I hope the thread is still active! Thanks in advance
     
  27. Damast

    Damast

    Joined:
    Apr 25, 2019
    Posts:
    13
    I think you can achieve this by building your own text field where the input is displayed. You can place it above by getting the mobile keyboard height, there is a script for that somewhere in this thread.
     
  28. larryPlayablStudios

    larryPlayablStudios

    Joined:
    May 15, 2018
    Posts:
    31
    Does anyone know if this supports undo during text input?
     
  29. Blacklister001

    Blacklister001

    Joined:
    Jun 13, 2016
    Posts:
    11
    Hi,
    I am using this asset in my project and it works really great in the editor and even on android devices. Now I have to build for iOS on xcode but I am facing an error in AdvancedInputField.cpp file in the IOS/Native folder in the xcode project. I am trying to run it on a simulator and it builds the app successfully but right after the Unity splash screen the app crashes and Xcode debugger shows the following logs.

    dyld[13251]: missing symbol called
    dyld config: DYLD_SHARED_CACHE_DIR=/Users/mac/Library/Developer/CoreSimulator/Caches/dyld/22C65/com.apple.CoreSimulator.SimRuntime.iOS-16-2.20C52 DYLD_ROOT_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot DYLD_LIBRARY_PATH=/Users/mac/Library/Developer/Xcode/DerivedData/Unity-iPhone-gfwluwlhmxhfsegvtubxrmgfvhop/Build/Products/ReleaseForRunning-iphonesimulator DYLD_INSERT_LIBRARIES=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/usr/lib/libMainThreadChecker.dylib:/usr/lib/libRPAC.dylib:/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib DYLD_FRAMEWORK_PATH=/Users/mac/Library/Developer/Xcode/DerivedData/Unity-iPhone-gfwluwlhmxhfsegvtubxrmgfvhop/Build/Products/ReleaseForRunning-iphonesimulator DYLD_FALLBACK_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks DYLD_FALLBACK_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot/usr/lib
    CoreSimulator 857.14 - Device: iPhone 14 Pro (F231B87E-FC15-4093-9A09-091126A15983) - Runtime: iOS 16.2 (20C52) - DeviceType: iPhone 14 Pro
    (lldb)



    And the xcode highlights a portion of code in the AdvancedInputField.cpp class. This the code that gets highlighted.

     // Native function invocation
    reinterpret_cast<PInvokeFunc>(_nativeKeyboard_initialize)(____onTextEditUpdate0_marshaled, ____onAutofillUpdate1_marshaled, ____onKeyboardShow2_marshaled, ____onKeyboardHide3_marshaled, ____onKeyboardDone4_marshaled, ____onKeyboardNext5_marshaled, ____onKeyboardCancel6_marshaled, ____onSpecialKeyPressed7_marshaled, ____onKeyboardHeightChanged8_marshaled, ____onHardwareKeyboardChanged9_marshaled);


    I donot have much expertise in the IOS department but I was able to build the app on IOS before adding the AdvancedInputField 2.

    If anyone knows the iOS and can look into this problem im having and guide me on how to get this fixed.

    Thank you.
     
  30. Blacklister001

    Blacklister001

    Joined:
    Jun 13, 2016
    Posts:
    11
    Can someone please take a look at this and tell me how to fix it? Anyone?
     
  31. CodeFluegel

    CodeFluegel

    Joined:
    Apr 8, 2015
    Posts:
    5
    have u got any new insights on this - can confirm I also experience this bug.
     
  32. Serrey

    Serrey

    Joined:
    Oct 2, 2018
    Posts:
    3
    I'm not sure why this bug occurs, however, if you manually create input fields without copying them, all inputs function normally.
     
  33. CodeFluegel

    CodeFluegel

    Joined:
    Apr 8, 2015
    Posts:
    5
    @Serrey
    It seems this is connected to the fieldtype which is used for entering the formular values such as 'name', 'surname', 'password' etc....
    All fields having the same type seems to be connected. This assumes that the writing in that input fields trigger somehow the insert functionality and therefore all same types are filled. Got no solution till now other than just setting this types only once per type(which is not really great since fields occure more often in different contexts)...
     
  34. novaVision

    novaVision

    Joined:
    Nov 9, 2014
    Posts:
    518
    Guys, do you have the same issue with auto-corrections on iOS - it suggests the password only and doesn't matter what settings input field has.
     
  35. Farshadfarzan368

    Farshadfarzan368

    Joined:
    Sep 10, 2022
    Posts:
    73
    The size of the ٍEmoji is not adjusted in different spacing Plese Help me
     

    Attached Files:

    vlasenkoalexey likes this.
  36. r4rahmat789

    r4rahmat789

    Joined:
    Jul 29, 2022
    Posts:
    3
    Hi, I want to use the Emoji's In My game But when try to Import It there is Error Showing
    upload_2023-6-2_10-33-11.png
     
  37. dev-concappt-media

    dev-concappt-media

    Joined:
    May 9, 2018
    Posts:
    2
    Did you solve this issue? Or how did you do it?
     
  38. RahmatAli_Noob

    RahmatAli_Noob

    Joined:
    Sep 13, 2022
    Posts:
    74
    Hello Everyone!

    I Explore About this Package and want to Use it in My game But when I try to Import it. It is Showing me the Error On the UnityEngine.InputSystem that I Am Missing the reference.

    But when try to use the InputSystem With Any other script it work perfectly fine.
    Here are the Screenshots added for the Reference.
    @jpienbro @fennecx_support
    Your Help will be Appreciated, Thanks in Advance.

    upload_2023-6-13_17-17-17.png
     

    Attached Files:

  39. TreasureHunt1

    TreasureHunt1

    Joined:
    May 24, 2021
    Posts:
    3
    i ma fa
    Hi there
    I am facing this also
    did you find the solution???
     
  40. TreasureHunt1

    TreasureHunt1

    Joined:
    May 24, 2021
    Posts:
    3
    did you find the solution of this????
     
  41. RahmatAli_Noob

    RahmatAli_Noob

    Joined:
    Sep 13, 2022
    Posts:
    74
    No I Didn't find the Solution for the Advance Input Field 2
     
  42. GregMcM

    GregMcM

    Joined:
    Jan 14, 2018
    Posts:
    10
    I forgot where I found it, but I believe this package from Fennecx fixes the errors you are encountering. Just do a Import Package > Custom Package and import this package into your project.

    Like I said, sorry... I forgot where I got the package from, so use at your own risk, but it is working for me to fix the emoji errors.
     

    Attached Files:

    nishiroshiro likes this.
  43. GregMcM

    GregMcM

    Joined:
    Jan 14, 2018
    Posts:
    10
    See my reply to r4rahmat just now.
     
  44. odysoftware

    odysoftware

    Joined:
    Jul 21, 2015
    Posts:
    84
    Does anyone know an easy way to allow Windows Emoji Input with this input box? At the moment if you want to add emoji icons from Windows 10/11 emoji picker, those just get ignored and not inserted?
     
  45. sheralex1998

    sheralex1998

    Joined:
    Apr 4, 2020
    Posts:
    5
    Hi!

    Did you fix this bug somehow?
    Maybe can change the settings so as not to catch a bug?
     
  46. Ardito92ITA

    Ardito92ITA

    Joined:
    Apr 1, 2014
    Posts:
    37
    Hi,
    your resource is really nice! I've been using it for a few days and I'm quite happy with it.

    I found and fixed a bug:
    I have an AdvancedInputField in my scene, in which I have assigned a custom method in the "OnBeginEdit" events to not close the keyboard when clicking out:
    Code (CSharp):
    1. public void OnBeginEdit()
    2.      {
    3.          test.ShouldBlockDeselect = true;
    4.      }
    In my script I have this method to set ShouldBlockDeselect = false;
    Code (CSharp):
    1. private void LateUpdate()
    2.      {
    3.          if(Input.GetKeyDown(KeyCode.Escape))
    4.          {
    5.              test.ShouldBlockDeselect = false;
    6.              test.ManualDeselect();
    7.          }
    8.      }
    In the editor it works fine, but on my Redmi Note 9 Pro there is a bug:
    When I hit the ESC key the AdvancedInputField stays selected even though the keyboard is gone.

    I went through your code, and in the InputFieldEngine script inside the Deselect method I added 2 lines of code which seems to fix the problem:
    Code (CSharp):
    1. internal void Deselect(EndEditReason reason)
    2. {
    3. endEditReason = reason;
    4. EventSystem.current?.SetSelectedGameObject(null);
    5. EndEditMode(); //<-- Added
    6. DisableSelection(); //<-- Added
    7. }
    Could you add this change in the next project update?

    Thanks again for this great resource! <3
     
    Emanx140 likes this.
  47. Ardito92ITA

    Ardito92ITA

    Joined:
    Apr 1, 2014
    Posts:
    37
    HI,
    I noticed that on Android with a Redmi note 9 Pro device, when you click on any AdvancedInputField, a glitch occurs before the keyboard opens, the whole screen is stretched, I think this bug comes from the positioning of the AdvancedInputField above the keyboard, Is it possible to disable the automatic placement of the AdvancedInputField above the keyboard or fix this glitch somehow?

    Thanks for your attention
     
  48. vlasenkoalexey

    vlasenkoalexey

    Joined:
    Jun 10, 2023
    Posts:
    6
    Old thread, replying in case someone else has same issue. I spent couple of hours trying to figure it out.
    My understanding is that when you import your image file, for example sheet_google_32.png, as image asset, Unity has a settings to resize it. When those settings are applied the size won't match of what offset calculations expect. The fix is to tell it not to resize it. See screenshot.
    Capture.PNG
     
  49. vlasenkoalexey

    vlasenkoalexey

    Joined:
    Jun 10, 2023
    Posts:
    6
    Had same issue, looks like for some reason AdvancedInputField doesn't have a reference to UnityEngine.InputSystem.
    You can add it manually, open AdvancedInputField.asmdef in Unity inspector and add reference here.
    Capture.PNG
     
  50. AlekseevAV

    AlekseevAV

    Joined:
    Jul 20, 2017
    Posts:
    6
    I've had the same problem.

    Disabling minify release solved the issue: https://docs.unity3d.com/ScriptReference/PlayerSettings.Android-minifyRelease.html