Author Topic: My NGUI suggestions.  (Read 57814 times)

Grhyll

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 32
    • View Profile
Re: My NGUI suggestions.
« Reply #15 on: October 26, 2012, 09:19:46 AM »
Quote
Better label control
I would like to see some more control in the UILabel component. Especially the ability to set character spacing. I know i can set this on the font prefab. But i see no reason why you shouldn't be able to set this individually on each UILabel.
Some other controls like individual character rotation and stuff like that would also be nice. But perhaps this functionality should be put in a separate UILabelPluss component to not clutter things.
This would interest me as well! Especially the part about controlling each character individually, even if I guess it's not the easiest one...

One thing that could also be useful on those UILabel would be to be able to get their size (the size of the total label, instead of the scale of the font).

ShinyMark

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 11
    • View Profile
Re: My NGUI suggestions.
« Reply #16 on: March 28, 2013, 11:47:31 AM »
Attached is a quick and dirty port of SlicedTiledSprite to NGUI 2.5.0c / Unity 4.1. I moved the functionality into UISprite.cs to match the recent Sprite refactor.

I had to change how spritePixels and texPixels were calculated in SlicedTiledFill() to function correctly with our setup. To be honest, I don't know why I had to make the change to that code and I don't have time to research why.

I hope this is helpful for someone.

-Mark / shinyshoe.com

PabloAM

  • Jr. Member
  • **
  • Thank You
  • -Given: 1
  • -Receive: 0
  • Posts: 58
    • View Profile
Re: My NGUI suggestions.
« Reply #17 on: March 28, 2013, 11:52:16 AM »
Attached is a quick and dirty port of SlicedTiledSprite to NGUI 2.5.0c / Unity 4.1. I moved the functionality into UISprite.cs to match the recent Sprite refactor.

I had to change how spritePixels and texPixels were calculated in SlicedTiledFill() to function correctly with our setup. To be honest, I don't know why I had to make the change to that code and I don't have time to research why.

I hope this is helpful for someone.

-Mark / shinyshoe.com


Just added to my proyect and works perfect!
I hope this going to be added to the next version :)
« Last Edit: March 28, 2013, 12:05:30 PM by PabloAM »

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: My NGUI suggestions.
« Reply #18 on: March 30, 2013, 08:21:26 AM »
Cool! I've been faking these by having two sprites (one sliced and one tiled, where the sliced doesn't fill center and the tiled doesn't draw the edges).

Attached is a quick and dirty port of SlicedTiledSprite to NGUI 2.5.0c / Unity 4.1. I moved the functionality into UISprite.cs to match the recent Sprite refactor.

I had to change how spritePixels and texPixels were calculated in SlicedTiledFill() to function correctly with our setup. To be honest, I don't know why I had to make the change to that code and I don't have time to research why.

I hope this is helpful for someone.

-Mark / shinyshoe.com

apparition

  • Guest
Re: My NGUI suggestions.
« Reply #19 on: June 27, 2013, 03:49:24 PM »
Thank you YourUncleBob and ShinyMark for sharing this script!  This is exactly what I was looking for.

knifesk

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 10
    • View Profile
Re: My NGUI suggestions.
« Reply #20 on: July 18, 2013, 12:16:51 PM »
this is not working with NGUI 2.6.3 :(

Malzbier

  • Jr. Member
  • **
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 93
    • View Profile
Re: My NGUI suggestions.
« Reply #21 on: July 19, 2013, 02:34:15 AM »
Thanks for sharing ShinyMark, but did you read the head of the file you posted?

  1. //----------------------------------------------
  2. //            NGUI: Next-Gen UI kit
  3. // Copyright © 2011-2012 Tasharen Entertainment
  4. //----------------------------------------------

You are not allowed to distribute NGUI code.

You could send it to the NGUI Author or publish a diff file.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: My NGUI suggestions.
« Reply #22 on: July 19, 2013, 04:41:20 AM »
In this case it's just one file, so I don't mind.

jamespaxi

  • Guest
Re: My NGUI suggestions.
« Reply #23 on: August 03, 2013, 09:51:10 AM »
Thanks immensely for sharing the Tiled Sprite workaround! :)

But is this still the way to go for Sliced-Tiled sprites? Replacing the UISprite class?

broken

  • Full Member
  • ***
  • Thank You
  • -Given: 1
  • -Receive: 4
  • Posts: 140
    • View Profile
Re: My NGUI suggestions.
« Reply #24 on: October 24, 2013, 11:01:58 AM »
How many triangles is that window? Looking at it, I'm estimating... a ton.

Aren, what is the normal amount of Triangles in order to make a tiled background is (for UI)?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: My NGUI suggestions.
« Reply #25 on: October 24, 2013, 11:48:22 PM »
There is no "normal". The less the better, but also big textures waste a lot of space. 100x100 would be my suggestion.

broken

  • Full Member
  • ***
  • Thank You
  • -Given: 1
  • -Receive: 4
  • Posts: 140
    • View Profile
Re: My NGUI suggestions.
« Reply #26 on: October 25, 2013, 01:28:10 AM »
There is no "normal". The less the better, but also big textures waste a lot of space. 100x100 would be my suggestion.

Ok, thank you.
In the near future you plan to add SlicedTiledSprite to the core NGUI?

broken

  • Full Member
  • ***
  • Thank You
  • -Given: 1
  • -Receive: 4
  • Posts: 140
    • View Profile
Re: My NGUI suggestions.
« Reply #27 on: October 27, 2013, 12:42:32 PM »
Release notes NGUI 3.0.3:
Quote
- NEW: UIInput has been redone, and now supports moving the caret as well as copy/paste keys in the editor.

Movement of the caret is only available for the editor? I thought it would be and in the component and happy, and it appears not. Not seeing the caret is not very convenient to write the text, for example if I wanted to go back to some part of the line but I can not see exactly where the caret :( I think this functionality must be in a box NGUI (not additional asset from store) :(
« Last Edit: October 27, 2013, 01:03:39 PM by broken »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: My NGUI suggestions.
« Reply #28 on: October 27, 2013, 10:48:12 PM »
Everywhere, not just the editor. Previously copy/paste didn't work in the editor, now it does. Caret wasn't movable before, now it is.

broken

  • Full Member
  • ***
  • Thank You
  • -Given: 1
  • -Receive: 4
  • Posts: 140
    • View Profile
Re: My NGUI suggestions.
« Reply #29 on: October 28, 2013, 12:08:38 AM »
Everywhere, not just the editor. Previously copy/paste didn't work in the editor, now it does. Caret wasn't movable before, now it is.

Repeatedly updated and now I see, yeah, I'm sorry.
But without caret blinking and mouse click caret positioning?