GithubHelp home page GithubHelp logo

Overriding width / height about pixi-haxe HOT 4 CLOSED

pixijs avatar pixijs commented on July 22, 2024
Overriding width / height

from pixi-haxe.

Comments (4)

adireddy avatar adireddy commented on July 22, 2024

Hi @ianharrigan, I see your point but I don't think it's possible to add getters and setters at extern level.

May be I am wrong as I haven't tried that before. If you have time can you please give it a go probably in the Container class in externs and let me know if it works.

from pixi-haxe.

ianharrigan avatar ianharrigan commented on July 22, 2024

Cool, thanks for the answer, ill try it when i get a moment, at the moment, ive actually found another way to do it... Ive basically created my own extern:

@:native("PIXI.Container")
extern class HaxeUIPixiContainer extends DisplayObject {
}

Which is basically a copy of yours without the width / height and then i set them in my parent class, it means i dont have to touch your externs and can still have control over my version of it... So far they all seem to play nicely together.

Still, ill see if i can find out more about using actual setters, i had a quick play, and apart from var width(default, default):Float (which is no good really) i couldnt figure it out.

from pixi-haxe.

adireddy avatar adireddy commented on July 22, 2024

Closing this for now...

from pixi-haxe.

ianharrigan avatar ianharrigan commented on July 22, 2024

Yeah, sorry, totally forgot...

from pixi-haxe.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.