All Projects → dingjibang → GDX-HTML

dingjibang / GDX-HTML

Licence: other
using HTML + CSS + JS to build libGDX UI!

Programming Languages

java
68154 projects - #9 most used programming language
groovy
2714 projects

Projects that are alternatives of or similar to GDX-HTML

EasyStage
A stage profile tool for libgdx
Stars: ✭ 17 (-19.05%)
Mutual labels:  libgdx, stage
Renderer
Simple, lightweight and faster response (JSON, JSONP, XML, YAML, HTML, File) rendering package for Go
Stars: ✭ 220 (+947.62%)
Mutual labels:  xml, renderer
magic-api-spring-boot-starter
magic-api的spring-boot-starter版本
Stars: ✭ 30 (+42.86%)
Mutual labels:  xml
MultiStateToggleButton
Android's ToggleButton offers only two states, MultiStateToggleButton fixes this by offering as many states depending on the number of drawable resources passed in.
Stars: ✭ 20 (-4.76%)
Mutual labels:  xml
DiligentFX
High-level rendering components
Stars: ✭ 116 (+452.38%)
Mutual labels:  renderer
Panorama360
Projekt przejściowy do projektu Magisterskiego. Android, LibGDX, OpenCV, Camera, SurfaceView, stitching, panorama, sphere, gyroscope
Stars: ✭ 52 (+147.62%)
Mutual labels:  libgdx
TenPatch
An alternative to libGDX's 9patch implementation.
Stars: ✭ 35 (+66.67%)
Mutual labels:  libgdx
webgpu-renderer
A simple renderer implemented by WebGPU, includes a builtin path tracing pipeline.
Stars: ✭ 122 (+480.95%)
Mutual labels:  renderer
Server-Help
💻 This VSTO Add-In allows the user to ping a list of servers and creates a file for Microsoft Remote Desktop Manager an Excel table. This is used for quickly determining which servers are offline in a list. It is written in 3 different versions as a VSTO Add-In in C# and VB.NET as well as a VBA Add-In.
Stars: ✭ 21 (+0%)
Mutual labels:  xml
xast
Extensible Abstract Syntax Tree
Stars: ✭ 32 (+52.38%)
Mutual labels:  xml
SAF-T-AO
Official XSD from the Government of Angola for use in SAF-T AO
Stars: ✭ 42 (+100%)
Mutual labels:  xml
lambda-client
A Source Engine BSP Renderer written in Go.
Stars: ✭ 14 (-33.33%)
Mutual labels:  renderer
granitic
Web/micro-services and IoC framework for Golang developers
Stars: ✭ 32 (+52.38%)
Mutual labels:  xml
ore-ui
💎 Building blocks to construct game UIs using web tech.
Stars: ✭ 122 (+480.95%)
Mutual labels:  renderer
spring-mvc3-javaconfig
A Java Spring MVC 3 app configured without XML. Also uses Servlet 3 API to bypass web.xml
Stars: ✭ 23 (+9.52%)
Mutual labels:  xml
xml2json
Xml To Json
Stars: ✭ 32 (+52.38%)
Mutual labels:  xml
edireader
EDIReader is a flexible and lightweight EDI parser, written in pure Java with many integration options. It has handled millions of transactions in a wide variety of products, services, industries, platforms, and custom integrations. Available as the open source Community Edition and the Premium Edition with added-value modules.
Stars: ✭ 80 (+280.95%)
Mutual labels:  xml
onixcheck
ONIX validation library and commandline tool
Stars: ✭ 20 (-4.76%)
Mutual labels:  xml
asl
A C++ cross-platform library including JSON, XML, HTTP, Sockets, WebSockets, threads, processes, logs, file system, CSV, INI files, etc.
Stars: ✭ 44 (+109.52%)
Mutual labels:  xml
learn-xquery
A list of great articles, blog posts, and books for learning XQuery
Stars: ✭ 33 (+57.14%)
Mutual labels:  xml

GDX-HTML

Using HTML + CSS + JS to build libGDX UI!

用HTML+CSS+JS构建libGDX的UI!

点我查看中文说明

Image Image

仍在开发(Still developing)


怎么用(how to use)

Stage stage = HTMLStage.buildPath(path-to-html-file);
//done!

support CSS / HTML

"💚" is full support, and light performance cost css styles

(Close to LibGDX properties, so don't need to spend too much performance)

"❤️" is full support, and is heavy performance cost css styles

(In order to be compatible with css properties, some heavy-performance-cost hack tricks have been used)

"💙" is coming soon

(It's in dev)

"💔" is unsupport css styles / different with real world html+css

(It may be too wasteful performance, or just too difficult to implementation 😭)



Box

  • 💚 width (px / em)
  • 💚 height (px / em)
  • 💚 padding (padding-left / right / top / bottom)
  • 💚 margin (margin-left(auto) / right(auto) / top / bottom)

Text control

  • 💚 font-size (px)
  • 💚 color (color-name / hex / rgb / rgba)
  • 💚 text-align (left / center / right)
  • ❤️ line-height (px)
    • Setting the line-height property will cause the text dom to be layout multiple times.
    • The scene2d.Label of libgdx does not support line-height. For compatibility, it will cost additional performance
    • So if there is only a single line of text, it is recommended to set padding / height.
  • ❤️ letter-spacing (px)
    • Setting the letter-spacing property will cause the text dom to be layout multiple times.
    • The scene2d.Label of libgdx does not support letter-spacing. For compatibility, it will cost additional performance
  • 💚 -gdx-markup (true)
    • LibGDX text markup color language support.
    • Once set, it will not be canceled, even if you set it to "false".
  • ❤️ -gdx-wrap (true / false)
    • The default is FALSE to save performance. When enabled, LibGDX native wrap support will be used, but the element or parent(s) element must be set to a fixed width.
    • Setting the gdx-wrap property will cause the font size to be layout multiple times.
    • 💔 When you set an element to "-gdx-wrap: true", it is not allowed to contain any child elements (except plain text), If you want to use colorful text, please set -gdx-markup to true.

Image / Texture

  • 💚 <img src="..." />
  • 💚 -gdx-image-scaling
    • Image is loaded asynchronously by default, which does not block the rendering of html, but when the Image is loaded, it will be re-layout, which will make the whole interface flash and affect performance. If your image is not very large, set <img async="false" src="..." /> and then becomes synchronous load. You can also preset a fixed width and height for the Image.
    • To set the scaling of <img />, you can use this css property, value is enum name of com.badlogic.gdx.utils.Scaling, like "fit" or "none".

Rich background

  • 💚 background-color (color-name / hex / rgb / rgba)
  • 💙 background-image
  • 💙 background-position
  • 💙 background-size

Positioning method

  • 💚 position: static
  • 💙 position: relative
  • 💙 position: absolute
  • 💙 position: fixed
  • 💔 position: sticky

Display

  • 💚 display: inline
  • ❤️ display: inline-block
  • ❤️ display: block
    • display block / inline-block uses an ugly implementation, sometimes it may not be the same as what the browser shows.
  • 💙 display: table

Table layout

  • 💚 <table /> with display: table
  • 💚 <tr /> with display: table-row
  • 💚 <td /> <th /> with display: table-cell
  • 💚 vertical-align
    • 💔 Table directly contains a Div is illegal, unless the div is set to display: table-cell, otherwise any display is weird.
    • 💔 For performance, <table> or display: table, is not support margin or padding properties. As an alternative, you can include a container outside of <table> and set padding.
    • 💔 Table is too metaphysical, it is likely to be different from the browser display.
    • 💔 TBody, THead and TR are fake and will not be read by the rendering engine(Just used to call row()), so don't think of it here.
    • Each cell will be expand() by default, unless you set a size, if you set the width or height but do not show what you want, you can try to set the size (fixed value, or percentage) for each column of the cell.

Font

  • 💙 font-family

Border

  • 💙 border

Float

  • 💔 Nope, float is SHIT.

Selectors / Pseudo selectors

  • 💙 :hover
  • 💙 :active
  • 💚 :lt / :gt / :eq / :first-child / :last-child
  • 💚 :has(selector) / :not(selector)
  • 💚 :contains(text)
  • 💚 See link to visit all support selectors / pseudo selectors

Event listener

  • 💙 Coming soon.

JavaScript Support

  • 💙 Coming soon.

And more...

  • 💚 💚 💚

Help us

  • This project is expected to be too large, I need contributors. Please help us.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].