Closed jgcop closed 3 years ago
Hi,
I think you need to assign it to a variable since its building a UI from a macro (ie, quite a bit of code being inserted in)...
var x = ComponentMacros.buildComponent(“Assets/Xml/UI.xml”);
app.addComponent(x);
Should work...
Although, thats strange that that sample has that method... ill check it out.
i try it out with: line 12: var x = ComponentMacros.buildComponent(“Assets/Xml/UI.xml”); line 13: app.addComponent(x);
same error like befor HaxeToolkit/haxe/lib/haxeui-core/0,0,3/haxe/ui/macros/ComponentMacros.hx:118: characters 24-26 : Unknown identifier : c0 Source/Main.hx:12: characters 19-70 : Called from macro here HaxeToolkit/haxe/lib/haxeui-core/0,0,3/haxe/ui/macros/ComponentMacros.hx:119: characters 24-26 : Unknown identifier : c0 Source/Main.hx:12: characters 19-70 : Called from macro here Source/Main.hx:13: characters 20-29 : Void should be haxe.ui.core.Component Source/Main.hx:13: characters 20-29 : For function argument 'component'
Yeah, it works fine for me either way - any chance you can zip the whole project up and attach it?
my version
Its pretty weird, works just fine for me:
And the error is really weird to as its at the macro stage...
EDIT: realised im on a crazy out of date openfl (3.6.1 - probably to test haxeui-flixel), let me update
really? this is my project? i don't understand this
the language ist very nice, haxeui is very nice, but i don't know, what i can do, that it runs without error?
Yeah, thats your project - just opened up the .hxproj and compile / ran, im just updating to latest openfl, maybe that has something to do with it...
What version of haxe are you using?
... same thing on openfl 7... :/ Not sure what it could be... very strange error... The project you sent works just fine...
windows 10 haxe 3.4.4 openfl 7 hxcpp git lime 6.0.1
from all the newest one haxe 3.4.4
hxcpp not from git
Can you do me a favour? Can you try git versions of haxeui-core and haxeui-openfl?
can you tell me the command? for the git?
haxelib git haxeui-core https://github.com/haxeui/haxeui-core
haxelib git haxeui-openfl https://github.com/haxeui/haxeui-openfl
it doesn't work the same error i install both from git
my computer is windows 10 pro, i think is not the problem
could it be, my hxcpp is not from git?
its a super strange error, i wonder if its something to do with the IDE?? What happens if you do:
openfl test windows
from the command line? Does anything else work? eg:
openfl test html5
openfl test neko
?
What about an empty openfl project (no haxeui)?
λ openfl test neko
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:129: WARNING: no class found for component: tabbar
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:116: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:117: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
Source/Main.hx:13: characters 20-29 : Void should be haxe.ui.core.Component
Source/Main.hx:13: characters 20-29 : For function argument 'component'
λ openfl test windows
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:129: WARNING: no class found for component: tabbar
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:116: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:117: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
Source/Main.hx:13: characters 20-29 : Void should be haxe.ui.core.Component
Source/Main.hx:13: characters 20-29 : For function argument 'component'
λ openfl test html5
Warning: Could not generate .eot web font for "C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-openfl/git/./assets/fonts/Roboto-Regular.ttf"
Warning: Could not generate .woff web font for "C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-openfl/git/./assets/fonts/Roboto-Regular.ttf"
Warning: Could not generate *.svg web font for "C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-openfl/git/./assets/fonts/Roboto-Regular.ttf"
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:129: WARNING: no class found for component: tabbar
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:116: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
C:/laragon/bin/HaxeToolkit/haxe/lib/haxeui-core/git/haxe/ui/macros/ComponentMacros.hx:117: characters 24-26 : Unknown identifier : c0
Source/Main.hx:12: characters 19-70 : Called from macro here
Source/Main.hx:13: characters 20-29 : Void should be haxe.ui.core.Component
Source/Main.hx:13: characters 20-29 : For function argument 'component'
ok, so this is the issue:
WARNING: no class found for component: tabbar
Now just to figure out why...
... and i know why... its because it its looking for module.xml
in haxeui-core, but its set to skip "bin"... but thats just to speed things up - give me a few mins... ill work out a better way to do it.
This is the issue: https://github.com/haxeui/haxeui-core/issues/184
Ok, original issue (184) fixed now (i think) - updated that issue - can you pull latest git versions and retest? Should (hopefully) be working now.
Cheers, Ian
i'm waiting for the finishing of compiling he stays at src/resources.cpp
for neko it works fine for html5 it works also fine for windows i try a new compiling, because he stays at scr/ resources .cpp along time
can you tell me, where i find a good starting point for use haxeui? a good tutorial for beginners, or a good blog for beginners?
i try a new round to compile for windows he stay at the same point a long time for neko and html5 no problems and very fast
i will tell you, if he finished compiling
Sounds like that might be a hxcpp / openfl issue (possibly), compilation is quite fast for me - are you using the IDE or openfl test ...
? Also, as far as haxeui2 resources, there arent that many... there is the repo you already found: https://github.com/r3d9u11/haxe-basics/tree/master/4_ExtLib/4.4_GuiFrameworks/4.4.2_HaxeUI
And also: https://github.com/haxeui/component-examples
(The former repo being MUCH fuller :) )
i using the IDE
@home it works also for windows
thx for all
if i find new errors, i will open new issues :-D
I try the following example for haxeui-openfl on windows 10: https://github.com/r3d9u11/haxe-basics/tree/master/4_ExtLib/4.4_GuiFrameworks/4.4.2_HaxeUI/4.4.2.1_SimpleGui/4.4.2.1.1_HaxeuiBackends/4.4.2.1.1.1_haxeui-openfl/4.4.2.1.1.1.1_Elements/TabBar
I try to compile it for Windows and get the following error: haxeui-core/0,0,3/haxe/ui/macros/ComponentMacros.hx:119: characters 24-25 : Unknown identifier : c0
Source/Main.hx:12: characters 20-71 : Called from macro here Source/Main.hx:12: characters 20-71 : Void should be haxe.ui.core.Component Source/Main.hx:12: characters 20-71 : For function argument ‘component’
Line 12 Main.hx: app.addComponent(ComponentMacros.buildComponent(“Assets/Xml/UI.xml”));
Line 118/119 ComponentMacros.hx: code.push(macro c0.script = $v{fullScript}); code.push(macro c0);
My dependencies: Windows 10 x64 actuate: [1.8.7]
flixel-addons: [2.5.0]
flixel-demos: [2.4.3]
flixel-templates: [2.4.6]
flixel-tools: [1.4.1]
flixel-ui: [2.2.0]
flixel: [4.3.0]
haxeui-core: [0.0.3]
haxeui-openfl: [0.0.2]
haxeui: [1.8.21]
hxcpp: [3.4.188]
hxcs: [3.4.0]
hxjava: [3.2.0]
hxLINQ: [1.2.0]
hxtools: [1.1.6]
kha: [16.1.2]
layout: [1.2.1]
lime-samples: [4.0.1]
lime: [6.0.1]
openfl-samples: [6.0.0]
openfl: [7.0.0]
snow: git [dev:C:\laragon\bin\HaxeToolkit\haxe\lib\snow\git]
snowfall: [0.0.16]
stablexui: [1.2.1]
waxe: [3.1.1]