Will there ever be a custom textbox?

0 favourites
  • 12 posts
From the Asset Store
Forget about default textbox restrictions, you can create sprites atop of the textbox
  • A plugin or feature to the program that allows you to edit the Textbox font and box image like you would a spritefont or sprite, would be very nice looking and useful on c2. Do you think this will ever be a feature or plugin in the future?

  • A more customtizable textbox has been asked from Scirra as a future feature numerous times. I hope they make it for Construct 3.

  • Considering that construct 2 is not yet complete that would be ignorant to wait til construct 3 to add it if they are going to add it. How did Scirra respond and if they hadn't whats stopping them from doing so?

  • You can customize it with CSS. Make it borderless and transparent, then put over any fancy sprite and you have your magic done.

  • for custom textbox with CSS: Tutorial written by Colludium https://www.scirra.com/tutorials/1283/css-your-buttons-and-textboxes

  • You can customize it with CSS. Make it borderless and transparent, then put over any fancy sprite and you have your magic done.

    The problem with using that to constantly change a spritefont is that there is no insertion point. Even now that I had made an insertion point sprite It cannot select text or be moved by mouse. I cannot find a workaround to force it to do these things with sprites, but a plugin or feature that allows you to easily edit each moving and non-moving part of a textbox like you would a sprite would be absolutely perfect. Obviously plugins and features take a while so right now I'm trying to simulate it. What do you suggest I do to add text selection and insertion point and text movement to this? Any help would be great!

  • You can customize it with CSS. Make it borderless and transparent, then put over any fancy sprite and you have your magic done.

    But can we set custom formatting for just parts of the text? Like making just one word bold or draw it with different color?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • But can we set custom formatting for just parts of the text? Like making just one word bold or draw it with different color?

    Are we still talking about TextBox object? Can't really figure out any project where you would want to have different formatting for various words in the input field . But anyway. No it is not possible to format only the part of the input text. You would have to do some hacks.

  • The problem with using that to constantly change a spritefont is that there is no insertion point. Even now that I had made an insertion point sprite It cannot select text or be moved by mouse. I cannot find a workaround to force it to do these things with sprites, but a plugin or feature that allows you to easily edit each moving and non-moving part of a textbox like you would a sprite would be absolutely perfect. Obviously plugins and features take a while so right now I'm trying to simulate it. What do you suggest I do to add text selection and insertion point and text movement to this? Any help would be great!

    I think I don't fully understand what you want to achieve.

    TextBox is an input field. It's basically an HTML input tag.

    <input type="{whatever}" name="{whatever}" id="{whatever}" />[/code:1s3vihd5]
    And from this place you can style it with CSS as on HTML page. So basically you can do a formatting with CSS to make it [b]look[/b] however you want to. So you can change a color, border, font, opacity etc. It's just about the way it is presented.
    
    Now keep in mind that this tag have also an [b]id[/b] attribute which allows you (C2 engine) to pick it individualy to work with it. So here we have JS (Java Script). With JS you can control the behaviour of elements. So this time it's not about the [b]look[/b] but the [b]functionality[/b]. In case of using C2 you don't have to use pure JS - C2 does it for you.
    
    I just wanted to highlight that you do have the possibility to manipulate both the look and the functionality of this element. By default you cannot use sprite fonts as an input text, but with some portion of creativity you have possibility to hack it.
    
    So if I understand you want to use sprife fonts as an input text and be able to highlight (select) this text with mouse etc.(?). Well that would require some tests to check what works what not. 
    
    For a first shoot I would put the input field transparent (no borders and shades). 
    1. Set input text transparent (same color as background). Now you have fully functioning TextBox, just nothing is visible. 
    2. Put a sprite font over text box (try to adjust sprite font size to be perfectly the same as the text in the TextBox).
    3. Now set an event that whenever Input text changes it will copy the text value from the input box into the sprite font.
    
    No idea how would it behave. Just a first thing in my mind.
  • Are we still talking about TextBox object? Can't really figure out any project where you would want to have different formatting for various words in the input field . But anyway. No it is not possible to format only the part of the input text. You would have to do some hacks.

    Oh, it seems I mixed it up with the normal text object. Sorry for that.

  • Oh, it seems I mixed it up with the normal text object. Sorry for that.

    Regarding the Text object. There is a plugin where you can do some fancy stuff. I saw it once but can't really remember the name. Anyway there are several plugins to do a fancy things with text.

    You might want to check the list and search for "text":

  • Regarding the Text object. There is a plugin where you can do some fancy stuff. I saw it once but can't really remember the name. Anyway there are several plugins to do a fancy things with text.

    You might want to check the list and search for "text":

    I guess those were the plugins I saw a while ago. They seemed fine, but I still think that for a basic object type like the Text object, Scirra should include a bit more customizability. And also, it was requested before. I'm not asking for complicated features, they just need to add the support for using the <span></span> tags basically. If it's already possible, then it's my mistake, but please tell me how can I do it.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)