Support => NGUI 3 Support => Topic started by: zhing on April 03, 2013, 10:09:50 PM
Title: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: zhing on April 03, 2013, 10:09:50 PM
This is the HTMLEngine for NGUI and Unity3D.GUI
It is based on Profixy's HTMLEngine-Mini. URL: http://html-engine-mini.googlecode.com/ (http://html-engine-mini.googlecode.com/)
This modified version has some NEW features. 1. Add NGUI support. It will render HTML with UILabel and UISprite. This package also contains a NGUI distribution version(No Editor). 2. Add animation image support for NGUI by UIAnimationSprite. 3. Change ‘div’ tag to ‘spin’. 4. Add ‘id’ attribution to ‘p’, ‘spin’, ‘img’ and ‘a’ tags. So the NGUI labels and sprites will use this id as their game object name. After the labels and sprites were generated, we can get them by id easily. 5. Fixed asia language characters line break bug. 6. Fixed iOS 'Strip Assembiles' issus. Platform: Windows, Mac, iOS, Android, Webplayer Online Demos: NGUI demo: http://www.goodres.com/html_engine/ngui.html (http://www.goodres.com/html_engine/ngui.html) Unity3D.GUI demo: http://www.goodres.com/html_engine/unity3d.html (http://www.goodres.com/html_engine/unity3d.html) Asset Store: URL: http://u3d.as/content/zhing/htmlengine-for-ngui-and-unity3d-gui/ (http://u3d.as/content/zhing/htmlengine-for-ngui-and-unity3d-gui/) Screenshots: 1. Sample (https://d2ujflorbtfzji.cloudfront.net/package-screenshot/3c42780a-7445-4eb2-93c2-9336487f0d5b_scaled.jpg)
2. Line based text effect (https://d2ujflorbtfzji.cloudfront.net/package-screenshot/cb402ba4-9330-49eb-9404-0d43d0827cf0_scaled.jpg)
3. Text based text effect (https://d2ujflorbtfzji.cloudfront.net/package-screenshot/139b6174-b3df-4afc-af69-13444a57c0e0_scaled.jpg)
4. Image and Animation Image (https://d2ujflorbtfzji.cloudfront.net/package-screenshot/91b2ec64-543d-4ec1-a24d-462b1095bfdd_scaled.jpg)
hmm, sounds interesting, can i implement web view with your plugin?
My plugin can only parse
<p>, <spin>, <img>, <font>, <effect>, <b>, <i> and <a>
tags, a subset of HTML tags. So you can't use it render the complex html page, but simple page with these tags only.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: rocki on April 06, 2013, 01:07:51 AM
Hi, we're exporting to Flash and NGUI works well on Flash. Does this plugin also work on Flash. Using unity pro 4.1.2f Thanks.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: shokinhan on May 11, 2013, 09:26:38 AM
HI, If I use the NGUI,How to use the library? Do you have demo code ?
Thanks very much!!!
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: jeldrez on May 14, 2013, 09:24:07 AM
HTML is working into localization files?
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: StridingDragon on June 19, 2013, 06:14:35 PM
Does this package work with NGUI's localization? Also, is there way to get a copy without the free NGUI version being part of it? I don't want the installation to completely mess with my existing project and installation.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on June 20, 2013, 06:30:02 PM
so far it appears localization has to have everything on 1 line, thats something to keep in mind.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on June 20, 2013, 06:31:04 PM
anyone know how to select a font thats in a different folder then htmlengine's fonts? i have "Arial Black" (Arial Black 36) , and no matter what i type for face, it cannot find arial black.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on June 24, 2013, 04:25:33 PM
could someone give an example of how to setup a font like, standard Arial, to work with the <font face=.... tag (e.g. i place Arial.ttf into html engine's Resources/fonts folder. then call <font face=Arial>...)
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: ddfire on June 26, 2013, 11:37:00 AM
The web link is broken, the correct one is http://u3d.as/content/zhing/html-engine-for-ngui-unity-gui/4pD
Also may i see the manul or any explanation on how to us it before i buy? i am really interested in this!!!!!! Thanks!!!!
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on July 03, 2013, 02:40:47 PM
so i had to rip out the current solution for grabbing fonts. however their solution for fonts, while it is explained a little in the demo. it needs its own dedicated Documentation section for adding fonts, in a text file.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: shokinhan on August 11, 2013, 07:24:31 AM
What 's the number about the last version?
I don't find the change log about the HTMLENgine!
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on September 26, 2013, 04:31:37 PM
Will there be an update to handle the new structure of NGUI 3.0.0 anytime soon?
Thanks, Justin
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on September 26, 2013, 04:32:39 PM
Will there be an update to handle the new structure of NGUI 3.0.0 anytime soon?
Thanks, Justin
did something break in html engine when using ngui 3?
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on September 26, 2013, 04:40:37 PM
Yes, I don't have the project on this computer but there were a few things that broke for me. I was able to "fix" most of them but somewhere there was a run of "GetHeight", "GetWidth", etc. that were totally broken and I was not sure how to address that.
The exact line was something like:
UIAtlas.Sprite tmp = uiAtlas.spriteList[i];
Because spriteList now returns SpriteData and not UIAtlas.sprite.
~Justin
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on September 30, 2013, 04:35:20 PM
In addition I have noticed that when I do some inline tags such as <i> or <b> that the spacing is off. So this sentence:
"Hello <i>NGUI</i> HTML"
Looks like this
"HelloNGUIHTML
Where I would hope it looks like this:
"Hello NGUI HTML
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on September 30, 2013, 04:41:51 PM
yeah i noticed the spacing issues, could you post some of the fixes you made, so that i could have a head start on fixes to implement.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on September 30, 2013, 04:49:53 PM
Yes I will try to find them tomorrow morning.
Are you the current developer on this HTML Engine?
~Justin
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on September 30, 2013, 04:54:06 PM
no, im using the html system in a product though and these bugs could hold up the update to ngui3.0 if the fixes are not within reach. I've had to fix and change many things about the way the engine handles atlases and fonts from the resources folder, to adding localization support.
So im hoping this system doesnt get out of date.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on October 02, 2013, 11:43:21 AM
I upgraded NGUI again to the newest and we are completely broken for the HTML engine. So any fixes I had are totally worthless at this point. I have had to revert and I am wondering if you had a fix for that spacing issue with in line tags?
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on October 02, 2013, 11:55:02 AM
my only solution right now is to use
after using the tag, sometimes 2 or 3, in rare cases 4 of those in a row.
i've also used it before a tag, when using <img> since images seem to have a small spacing issue as well.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on October 09, 2013, 11:09:32 AM
justiniso any luck with the newer versions of html engine?
we are not upgrading for a couple of weeks for stability reasons. just curious if you tested the latest version of html engine
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: justinISO on October 16, 2013, 08:57:44 AM
Yup, updated and it works great!
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: bdominguez on December 04, 2013, 09:30:41 AM
I can't find an email contact so I write here:
- I have one problem with NGUI 3.0.6. "NGUIText.CalculatePrintedSize" has two parameters and "UIFont.CalculatePrintedSize" has one parameter. I have had to changed that.
NGUIHTML.cs
- Also, there is no reference exposed to the compiler so we can ask for the label height, I have changed this:
/// <summary>
/// our html compiler
/// </summary>
private HtCompiler compiler;
public HtCompiler Compiler {
get{return compiler;}
}
Another problem is that you can't ask for label height after changed it because you have to wait one frame. I have changed the code to this:
/// <summary>
/// setting text here will raise changed flag
/// </summary>
publicstring html {
get{returnthis._html;}
set{
this._html =value;
this.changed=true;
Update();
}
}
Another one. It's really slow in performance to "FindInParents" every frame for a component. So I changed it:
html.html="<font size="+--currentSize +">"+ text +"</font>";
}
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: robq on December 04, 2013, 01:25:29 PM
HtEngine.GetCompiler(); already exists
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: lzt120 on December 16, 2013, 08:46:33 PM
Please add support for NGUI 3.701.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: Romano on December 20, 2013, 05:48:48 AM
Not working with NGUi 3.0.7 f3 !!!! I have many errors. How fix?!
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: knifesk on December 27, 2013, 09:12:03 AM
There's a horrid bug that I cant get to fix... When (a) maxLineWidth is set, and NGUI is (b) set to FixedSize (actually is not set to fixed size, but screen height is less than UIRoot Minimum Height) the text will always go beyond maxLineWidth. I am using dynamic fonts
Take a look: NGUIHTML maxLineWith is set to 1171pixels (clipping panel's width) Label generated by NGUIHTML is 1191pixels wide.. and it wont fit inside panel obviously.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: John.Bergman on December 30, 2013, 08:52:05 PM
Does this work with 3.0.8 and Unity 4.3? When I tried to add it, I got tons of compiler errors.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: lzt120 on January 04, 2014, 03:00:08 AM
How about support multy Atlas and multy Font ? In my case, two Atlas support request.
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: Mhason on February 17, 2014, 04:22:34 PM
Installation instructions if you are using NGUI 3+ (Paid)
1) A project with NGUI v3+ installed 2) html_engine_for_ngui_3.0.9f1 will be the only file you need other than any instructions you want. 3) Import html_engine_for_ngui_3.0.9f1
Very simple but not explained in the asset instructions.
Best Regards,
Lee
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: Orfen on April 25, 2014, 06:53:42 AM
Since ZHing seems like he doesn't offer any kind of support, and his documentation is lacking to say the least, im left asking here: Has anyone figured a way to compile the html on an already existing label?Thanks
Title: Re: HTMLEngine for NGUI and Unity3D.GUI [RELEASE]
Post by: lzt120 on September 15, 2014, 01:44:36 AM
Can this add-on support UIInput to show the Symbol ?