Discussion:
DWT on Mac OS X and with DMD 2
amehat
2014-03-23 22:57:17 UTC
Permalink
Hello everyone,

I apologize in advance for my english, I'm french and not good in
the language of Shakespeare.

I am running Mac OS X 10.9 and I use the DMD 2 compiler.
I try to compile a basic script that uses DWT
(https://github.com/d-widget-toolkit/dwt-mac) :

module main;

import dwt.widgets.Button;
import dwt.widgets.Display;
import dwt.widgets.Event;
import dwt.widgets.Listener;
import dwt.widgets.Shell;

void main (){
Display display = new Display ();
Shell shell = new Shell (display);

Button button = new Button (shell, DWT.NONE);
button.setSize(100,100);
button.setText("Click me");

shell.pack;
shell.open;


while (!shell.isDisposed ()){
if (!display.readAndDispatch ()) display.sleep ();
}
}

But when I compile, I have a lot of error (I use Xamarin).
Is that I forget things or is that I do not compile it right (dmd
-debug -gc "main.d" "-I/usr/share/dmd/src/" "-odobj/Debug"
"-of/Users/amehat/Projects/D-test/D-test/bin/Debug/D-test")?

md
"@/var/folders/80/82nj5n0n65196c_jq7ftllqw0000gn/T/tmp3f6ab167.tmp"
dwt/browser/AppFileLocProvider.d(107): Deprecation: octal
literals 0700 are deprecated, use std.conv.octal!700 instead
dwt/browser/AuthenticationEvent.d(28): Error: { } expected
following aggregate declaration
dwt/browser/AuthenticationEvent.d(28): Error: semicolon expected,
not '{'
dwt/browser/AuthenticationEvent.d(28): Error: Declaration
expected, not '{'
dwt/browser/AuthenticationEvent.d(53): Error: function
declaration without return type. (Note that constructors are
always named 'this')
dwt/browser/AuthenticationEvent.d(53): Error: no identifier for
declarator AuthenticationEvent(Widget widget)
dwt/browser/AuthenticationEvent.d(71): Error: unrecognized
declaration
dwt/browser/AuthenticationListener.d(27): Error: { } expected
following aggregate declaration
dwt/browser/AuthenticationListener.d(27): Error: semicolon
expected, not '{'
dwt/browser/AuthenticationListener.d(27): Error: Declaration
expected, not '{'
dwt/browser/AuthenticationListener.d(58): Error: unrecognized
declaration
dwt/browser/Browser.d(531): Error: semicolon expected following
function declaration
dwt/browser/Browser.d(531): Error: semicolon expected, not '{'
dwt/browser/Browser.d(531): Error: Declaration expected, not '{'
dwt/browser/Browser.d(533): Error: Declaration expected, not 'if'
dwt/browser/Browser.d(534): Error: Declaration expected, not
'return'
dwt/browser/Browser.d(994): Error: unrecognized declaration
dwt/browser/BrowserFunction.d(76): Error: function declaration
without return type. (Note that constructors are always named
'this')
dwt/browser/BrowserFunction.d(76): Error: no identifier for
declarator BrowserFunction(Browser browser, String name)
dwt/browser/BrowserFunction.d(80): Error: function declaration
without return type. (Note that constructors are always named
'this')
dwt/browser/BrowserFunction.d(80): Error: no identifier for
declarator BrowserFunction(Browser browser, String name, bool
create)
dwt/browser/BrowserFunction.d(139): Error: no identifier for
declarator Object function(Object[] arguments)
Exit code 1
Construction termin?e -- 23 erreurs, 0 avertissement
Jacob Carlborg
2014-03-24 13:39:38 UTC
Permalink
Post by amehat
Hello everyone,
I apologize in advance for my english, I'm french and not good in the
language of Shakespeare.
I am running Mac OS X 10.9 and I use the DMD 2 compiler.
I try to compile a basic script that uses DWT
Unfortunately, DWT for OS X is not ready yet. That code is still written
in D1. I plan to port it to D2 when it's working as good as the
Linux/Windows version. Any help is appreciated.
--
/Jacob Carlborg
amehat
2014-03-24 17:15:13 UTC
Permalink
Post by Jacob Carlborg
Post by amehat
Hello everyone,
I apologize in advance for my english, I'm french and not good in the
language of Shakespeare.
I am running Mac OS X 10.9 and I use the DMD 2 compiler.
I try to compile a basic script that uses DWT
Unfortunately, DWT for OS X is not ready yet. That code is
still written in D1. I plan to port it to D2 when it's working
as good as the Linux/Windows version. Any help is appreciated.
Hello,

thank you for your reply.

I am willing to help you, DWT MAC OS X is really important to me.
Nevertheless, I started D and over time, I still do not have much
time. But if I can afford to run the library on Mac, I would
gladly.
Jacob Carlborg
2014-03-25 07:36:18 UTC
Permalink
Post by amehat
Hello,
thank you for your reply.
I am willing to help you, DWT MAC OS X is really important to me.
Nevertheless, I started D and over time, I still do not have much time.
But if I can afford to run the library on Mac, I would gladly.
What I'm currently doing is running snippets from the snippets
directory. I'm also adding new snippets, both from the separate snippet
repository [1] and the original SWT Java snippets [2]. Then just trying
to make them all work.

[1] https://github.com/d-widget-toolkit/org.eclipse.swt.snippets
[2] http://www.eclipse.org/swt/snippets/
--
/Jacob Carlborg
FrankLike via Digitalmars-d-dwt
2014-05-12 14:24:48 UTC
Permalink
Post by Jacob Carlborg
Post by amehat
Hello,
thank you for your reply.
I am willing to help you, DWT MAC OS X is really important to
me.
Nevertheless, I started D and over time, I still do not have
much time.
But if I can afford to run the library on Mac, I would gladly.
What I'm currently doing is running snippets from the snippets
directory. I'm also adding new snippets, both from the separate
snippet repository [1] and the original SWT Java snippets [2].
Then just trying to make them all work.
[1] https://github.com/d-widget-toolkit/org.eclipse.swt.snippets
[2] http://www.eclipse.org/swt/snippets/
Good job.
Jacob Carlborg via Digitalmars-d-dwt
2014-05-12 18:56:23 UTC
Permalink
Post by FrankLike via Digitalmars-d-dwt
Good job.
Thanks :)
--
/Jacob Carlborg
FrankLike via Digitalmars-d-dwt
2014-05-14 10:07:52 UTC
Permalink
I'v compiled the all snippets examples,the examples are very
good,but no enableVisualStyles fuction in DWT,it will help dwt to
be nice.
You can look at the DFL's enableVisualStyles().

DFL /Application.d
// Should be called before creating any controls.
// This is typically the first function called in main().
// Does nothing if not supported.
void enableVisualStyles()

Thank you.

Frank
Jacob Carlborg via Digitalmars-d-dwt
2014-05-14 11:49:22 UTC
Permalink
I'v compiled the all snippets examples,the examples are very good,but no
enableVisualStyles fuction in DWT,it will help dwt to be nice.
You can look at the DFL's enableVisualStyles().
DFL /Application.d
// Should be called before creating any controls.
// This is typically the first function called in main().
// Does nothing if not supported.
void enableVisualStyles()
What does it do?
--
/Jacob Carlborg
FrankLike via Digitalmars-d-dwt
2014-05-14 13:03:49 UTC
Permalink
Post by Jacob Carlborg via Digitalmars-d-dwt
Post by FrankLike via Digitalmars-d-dwt
I'v compiled the all snippets examples,the examples are very
good,but no
enableVisualStyles fuction in DWT,it will help dwt to be nice.
You can look at the DFL's enableVisualStyles().
DFL /Application.d
// Should be called before creating any controls.
// This is typically the first function called in main().
// Does nothing if not supported.
void enableVisualStyles()
What does it do
Ican send a mail to you, ok to email?
Jacob Carlborg via Digitalmars-d-dwt
2014-05-14 16:58:02 UTC
Permalink
Post by FrankLike via Digitalmars-d-dwt
Ican send a mail to you, ok to email?
Sure.
--
/Jacob Carlborg
FrankLike via Digitalmars-d-dwt
2014-05-15 03:53:49 UTC
Permalink
Post by FrankLike via Digitalmars-d-dwt
Ican send a mail to you, ok to email?
Sure.
Can you tell me your email? Thank you.
Jacob Carlborg via Digitalmars-d-dwt
2014-05-15 06:25:49 UTC
Permalink
Post by FrankLike via Digitalmars-d-dwt
Can you tell me your email? Thank you.
You should be able to see here somewhere.
--
/Jacob Carlborg
FrankLike via Digitalmars-d-dwt
2014-05-15 10:21:29 UTC
Permalink
Post by Jacob Carlborg via Digitalmars-d-dwt
Post by FrankLike via Digitalmars-d-dwt
Can you tell me your email? Thank you.
You should be able to see here somewhere.
I've mailed to you.waiting for you to answer.

Thank you.

Frank

Loading...