Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Graphical examples doesn't work from command line #123

Open
ciscoheat opened this issue Sep 24, 2022 · 2 comments
Open

Graphical examples doesn't work from command line #123

ciscoheat opened this issue Sep 24, 2022 · 2 comments

Comments

@ciscoheat
Copy link
Contributor

I noticed that when starting an example that uses the graphics capabilities of trygve, they only work from the GUI. For example:

trygve -c examples/breakout.k -r

Crashes with:

line 0: FATAL: Bad call to Frame (1) constructor.
        In script `Frame.Frame'
        Called from script `Display.Display'
        Called from script `Breakout.Breakout'
        Called from script `Breakout.run'

Internal error in message dispatching: no `this' pushed?<init>:929
Exception in thread "main" java.lang.AssertionError
        at info.fulloo.trygve.run_time.RTMessageDispatcher.pushArgumentLoop(RTMessageDispatcher.java:270)
        at info.fulloo.trygve.run_time.RTMessageDispatcher$RTNonContextToContext.<init>(RTMessageDispatcher.java:929)
        at info.fulloo.trygve.run_time.RTMessageDispatcher.makeDispatcher(RTMessageDispatcher.java:87)
        at info.fulloo.trygve.run_time.RTExpression$RTMessage.run(RTExpression.java:773)
        at info.fulloo.trygve.run_time.RunTimeEnvironment.runner(RunTimeEnvironment.java:483)
        at info.fulloo.trygve.run_time.RunTimeEnvironment.run(RunTimeEnvironment.java:235)
        at info.fulloo.trygve.editor.BatchRunner.simpleRun(BatchRunner.java:61)
        at info.fulloo.trygve.editor.BatchRunner.processBatch(BatchRunner.java:48)
        at info.fulloo.trygve.editor.Main.main(Main.java:50)

Is there any possibility to get them working from command line as well?

@jcoplien
Copy link
Owner

What would it mean if a program asked for the current cursor coordinates in a program that had been invoked from the command line (which breakout.k indeed does)?

I don’t think I understand what you are envisioning.

@ciscoheat
Copy link
Contributor Author

I thought that starting the GUI and a trygve program using graphics was basically the same thing, so it would be handled by the underlying graphics framework?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants