https://linen.dev logo
Join Discord
Powered by
# haxe-ui
  • b

    bright-gpu-74537

    12/08/2022, 8:26 AM
    also, fyi, you might save yourself alot of headaches by using a custom component class (and
    haxe.ui.ComponentBuilder.build
    ) rather than
    fromFile
    ... future you would thank you 🙂
  • b

    bright-gpu-74537

    12/08/2022, 8:27 AM
    yeah, maybe ill renable the warnings, see if they still show all the time, and if not see about traces. Also, im sure there must be a way to see if you are using the build macro outside of a class, ill check, that should be able to be warned about too
  • f

    famous-alarm-22563

    12/08/2022, 8:27 AM
    the component-examples uses the deprecated api btw
  • b

    bright-gpu-74537

    12/08/2022, 8:27 AM
    i mean, most of the component examples are deprecated, im not even sure many of them will even compile...
  • b

    bright-gpu-74537

    12/08/2022, 8:28 AM
    maybe i should remove them temporarily until i fix them
  • f

    famous-alarm-22563

    12/08/2022, 8:28 AM
    and I've been using them as documentation 😬
  • b

    bright-gpu-74537

    12/08/2022, 8:29 AM
    im mean thats fair, they are there, but they are super out of date
  • b

    bright-gpu-74537

    12/08/2022, 8:29 AM
    i want to start a new set, a better set, but there is alot to go through
  • f

    famous-alarm-22563

    12/08/2022, 8:29 AM
    umm.. ok, where do I get my docs from again?
  • b

    bright-gpu-74537

    12/08/2022, 8:30 AM
    erm... source, api docs, here and component explorer? :/
  • f

    famous-alarm-22563

    12/08/2022, 8:31 AM
    okay 😓
  • b

    bright-gpu-74537

    12/08/2022, 8:32 AM
    yeah, certainly less that ideal... im trying to get the docs better since it seems more people are using haxeui, but its a long (and boring!) process, and then there is also a growing list of haxeui issues / enhancements and my "normal work"
  • b

    bright-gpu-74537

    12/08/2022, 8:35 AM
    i noticed the other day that even the guides (which are now part of the haxeui.org website) are using deprecated apis... 😮
  • b

    bright-gpu-74537

    12/08/2022, 8:42 AM
    so, btw, when i try
    var xxxxx = ComponentMacros.build("somexml.xml");
    i get a bunch of totally different compile errors certainly not
    must have a superclass of haxe.ui.core.Component
  • b

    bright-gpu-74537

    12/08/2022, 8:43 AM
    Copy code
    D:/work/HaxeUI/haxeui-core/haxe/ui/macros/ComponentMacros.hx:65: lines 65-67 : Array<haxe.macro.Field> should be haxe.macro.Expr
    D:/work/HaxeUI/haxeui-core/haxe/ui/macros/ComponentMacros.hx:65: lines 65-67 : ... Array<haxe.macro.Field> has no field expr
  • f

    famous-alarm-22563

    12/08/2022, 8:44 AM
    I love haxeui but I don't have the bandwidth to help :/ freelancing + being a student is hard work...
  • b

    bright-gpu-74537

    12/08/2022, 8:45 AM
    yeah, i feel that, sometimes im working 70-80 hour weeks, the last thing i want to do after that is write haxeui docs 😄
  • f

    famous-alarm-22563

    12/08/2022, 9:41 AM
    Can I trigger an hscript inside an xml file from regular haxe?
  • b

    bright-gpu-74537

    12/08/2022, 9:42 AM
    you can write "script" in an xml file, but its not hscript, its real haxe code
  • f

    famous-alarm-22563

    12/08/2022, 9:43 AM
    That makes sense now that I think about it so the question is: can I run a function inside from outside the xml file?
  • b

    bright-gpu-74537

    12/08/2022, 9:44 AM
    sure, it will become a member of the class: http://haxeui.org/builder/?1b35255a
  • b

    bright-gpu-74537

    12/08/2022, 9:44 AM
    oh, all of this will only work btw if you are using a the build macro in a custom component class
  • b

    bright-gpu-74537

    12/08/2022, 9:45 AM
    (which as i mentioned earlier, you probably want to do anyway, you'll get a bunch of benefits and future you will thank you)
  • f

    famous-alarm-22563

    12/08/2022, 9:45 AM
    Yeah.. it seems like i'll probably need to create a seperate custom component for each scene in my game and call it {SceneNameView} ...
  • b

    bright-gpu-74537

    12/08/2022, 9:46 AM
    i mean, if the UI / XML is different then yeah, each would probably need to be a custom view
  • b

    bright-gpu-74537

    12/08/2022, 9:46 AM
    (although there are various ways to share bits)
  • f

    famous-alarm-22563

    12/08/2022, 9:47 AM
    The main bits I need to share are some string formatting logic and default styles..
  • f

    famous-alarm-22563

    12/08/2022, 9:47 AM
    which brings up another question... Can i Have a global stylesheet?
  • b

    bright-gpu-74537

    12/08/2022, 9:48 AM
    sure, i think i mentioned the ways before
  • b

    bright-gpu-74537

    12/08/2022, 9:48 AM
    (lemme see if i can find it, maybe it was about something else)
1...132613271328...1687Latest