www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.announce - Tkd - Cross platform GUI toolkit based on Tcl/Tk

reply "Gary Willoughby" <dev nomad.so> writes:
Tkd v1.0.0-beta

https://github.com/nomad-software/tkd
http://code.dlang.org/packages/tkd

Overview

Tkd is a fully cross-platform GUI toolkit based on Tcl/Tk[1]. Tkd 
allows you to build GUI applications easily and with the 
knowledge of a consistent, native look and feel on every platform.

Why Tcl/Tk?

Tkd development was initiated based on the performance and uptake 
of the Tkinter[2] toolkit distributed as a standard part of the 
Python[3] programming language. Tkinter allows developers easy 
access to GUI programming with very little learning. Being the de 
facto GUI toolkit of Python has introduced more developers to GUI 
application programming and increased the popularity of the 
language as a whole. Tkd is an attempt to provide D with the same 
resource.

Supported platforms

Windows
Linux
Mac OSX

Documentation

Full HTML documentation is available inside the repository.

Notes

Because Tkd is based upon Tcl/Tk and being cross-platform in 
nature there are limitations on what can be achieved. While not 
as comprehensive as gtkd or qtd, Tkd offers a smaller and lighter 
alternative for quickly creating native GUI applications. See the 
readme in the repository for more detailed information.

[1]: http://www.tcl.tk/
[2]: https://wiki.python.org/moin/TkInter
[3]: https://www.python.org/
May 04 2014
next sibling parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/4/2014 12:18 PM, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd
Looks great, anxious to give this a try! BTW, on the main readme page, the links into the API docs don't appear to be working (although it might be a GitHub issue).
May 04 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/4/2014 12:44 PM, Nick Sabalausky wrote:
 On 5/4/2014 12:18 PM, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd
Looks great, anxious to give this a try! BTW, on the main readme page, the links into the API docs don't appear to be working (although it might be a GitHub issue).
I'm getting compile errors building the example (Win32 DMD 2.065.0):
 dub build --config=example
## Warning for package tkd, configuration example ## The following compiler flags have been specified in the package description file. They are handled by DUB and direct use in packages is discouraged. Alternatively, you can set the DFLAGS environment variable to pass custom flags to the compiler, or use one of the suggestions below: -Jsource/example/media: Use "stringImportPaths" to specify import paths in a compiler independent way Checking dependencies in 'C:\DevProj\tkd' Building configuration "example", build type debug Running dmd (compile)... source\tkd\interpreter\tcl.d(189): Error: not a property name.toStringz source\tkd\interpreter\tcl.d(189): Error: not a property value.to!string source\tkd\interpreter\tcl.d(189): Error: not a property to(value).toStringz source\tkd\widget\common\value.d(45): Error: template instance tkd.interpreter.tcl.Tcl.setVariable!string error instantiating source\example\example.d(36): instantiated from here: setValue!(Entry) source\example\example.d(36): Error: template instance tkd.widget.entry.Entry.Value!(_valueVariable, string).setValue!(Entry) error instantiating source\tkd\interpreter\tcl.d(93): Error: not a property format(script, _param_1, _param_2, _param_3).toStringz source\tkd\interpreter\tcl.d(97): Error: not a property Tcl_GetStringResult(this._interpreter).to!string source\tkd\dialog\colordialog.d(97): Error: template instance tkd.interpreter.tcl.Tcl.eval!(string, string, string) error instantiating source\example\example.d(51): instantiated from here: show!(ColorDialog) source\tkd\interpreter\tcl.d(93): Error: not a property format(script, _param_1, _param_2).toStringz source\tkd\interpreter\tcl.d(97): Error: not a property Tcl_GetStringResult(this._interpreter).to!string source\tkd\dialog\colordialog.d(101): Error: template instance tkd.interpreter.tcl.Tcl.eval!(string, string) error instantiating source\example\example.d(51): instantiated from here: show!(ColorDialog) source\tkd\interpreter\tcl.d(130): Error: not a property Tcl_GetStringResult(this._interpreter).to!string source\tkd\interpreter\tcl.d(132): Error: not a property result.to!string source\tkd\dialog\colordialog.d(104): Error: template instance tkd.interpreter.tcl.Tcl.getResult!string error instantiating source\example\example.d(51): instantiated from here: show!(ColorDialog) source\tkd\dialog\colordialog.d(104): Error: not a property this._tk.getResult source\example\example.d(51): Error: template instance tkd.dialog.colordialog.ColorDialog.show!(ColorDialog) error instantiating source\tkd\interpreter\tcl.d(93): Error: not a property format(script, _param_1, _param_2, _param_3, _param_4).toStringz source\tkd\interpreter\tcl.d(97): Error: not a property Tcl_GetStringResult(this._interpreter).to!string source\tkd\dialog\directorydialog.d(111): Error: template instance tkd.interpreter.tcl.Tcl.eval!(string, string, string, bool) error instantiating source\example\example.d(65): instantiated from here: show!(DirectoryDialog) source\tkd\interpreter\tcl.d(93): Error: not a property format(script, _param_1, _param_2, _param_3).toStringz source\tkd\interpreter\tcl.d(97): Error: not a property Tcl_GetStringResult(this._interpreter).to!string Error: Build command failed with exit code 1 Run 'dub help' for usage information.
May 04 2014
parent reply "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 4 May 2014 at 18:20:01 UTC, Nick Sabalausky wrote:
 On 5/4/2014 12:44 PM, Nick Sabalausky wrote:
 On 5/4/2014 12:18 PM, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd
Looks great, anxious to give this a try! BTW, on the main readme page, the links into the API docs don't appear to be working (although it might be a GitHub issue).
Strange, works fine here.
 I'm getting compile errors building the example (Win32 DMD 
 2.065.0):
Those errors are from the DMD -property flag being passed somewhere, have a look and remove it if you're passing it.
May 04 2014
next sibling parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/4/2014 2:39 PM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 18:20:01 UTC, Nick Sabalausky wrote:

 I'm getting compile errors building the example (Win32 DMD 2.065.0):
Those errors are from the DMD -property flag being passed somewhere, have a look and remove it if you're passing it.
Oh, I must have been running an old version of dub. It used to include -property by default but no longer does. Hmm, dub doesn't seem to be telling me its version...but I'm sure it's old, I'll update it.
May 04 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/4/2014 3:11 PM, Nick Sabalausky wrote:
 On 5/4/2014 2:39 PM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 18:20:01 UTC, Nick Sabalausky wrote:

 I'm getting compile errors building the example (Win32 DMD 2.065.0):
Those errors are from the DMD -property flag being passed somewhere, have a look and remove it if you're passing it.
Oh, I must have been running an old version of dub. It used to include -property by default but no longer does. Hmm, dub doesn't seem to be telling me its version...but I'm sure it's old, I'll update it.
Just updated to latest DUB release (v0.9.21), but now I'm getting this:
 dub build --force --config=example
x11: ["x11"] tcltk: ["tcltk", "x11"] tkd: ["tkd", "tcltk", "x11"] Building x11 configuration "library", build type debug. Running dmd... Building tcltk configuration "library", build type debug. Running dmd... ..\..\Users\Nick\AppData\Roaming\dub\packages\tcltk-8.6.1\.dub\build\library-debug-windows-x86-dmd-C9527B3CFF40A7D16A18C46 4EF00288\tcltk.lib: Error: multiple definition of tcl_38_307: _Tcl_Main and Tcl_Main: _Tcl_Main FAIL ..\..\Users\Nick\AppData\Roaming\dub\packages\tcltk-8.6.1\.dub\build\library-debug-windows-x86-dmd-C9527B3CFF40 7D16A18C4624EF00288 tcltk staticLibrary Error executing command build: DMD compile run failed with exit code 1
May 04 2014
next sibling parent reply "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:
 Just updated to latest DUB release (v0.9.21), but now I'm 
 getting this:
That's building with the config 'library'. If you want to run the example build with: dub --config=example in the root of the tkd repo.
May 04 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/4/2014 3:55 PM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:
 Just updated to latest DUB release (v0.9.21), but now I'm getting this:
That's building with the config 'library'. If you want to run the example build with: dub --config=example in the root of the tkd repo.
No, I did indeed use "--config=example", see my previous post. Even with your exact line above: dub --config=example I still get the same result.
May 04 2014
parent reply "Kyle Hunter" <kelethunter gmail.com> writes:
On Sunday, 4 May 2014 at 20:47:58 UTC, Nick Sabalausky wrote:
 On 5/4/2014 3:55 PM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:
 Just updated to latest DUB release (v0.9.21), but now I'm 
 getting this:
That's building with the config 'library'. If you want to run the example build with: dub --config=example in the root of the tkd repo.
No, I did indeed use "--config=example", see my previous post. Even with your exact line above: dub --config=example I still get the same result.
Same here.
May 04 2014
parent "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 4 May 2014 at 21:10:28 UTC, Kyle Hunter wrote:
 On Sunday, 4 May 2014 at 20:47:58 UTC, Nick Sabalausky wrote:
 On 5/4/2014 3:55 PM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:
 Just updated to latest DUB release (v0.9.21), but now I'm 
 getting this:
That's building with the config 'library'. If you want to run the example build with: dub --config=example in the root of the tkd repo.
No, I did indeed use "--config=example", see my previous post. Even with your exact line above: dub --config=example I still get the same result.
Same here.
I thought this sounded familiar, i raised this a few weeks ago with Sonke on the dub forums (still waiting for a reply.) http://forum.rejectedsoftware.com/groups/rejectedsoftware.dub/thread/1339/#post-1453 I can't reproduce it now. I've tested tkd successfully on Windows 7 64bit Windows XP 32bit Ubuntu 12.04 Mac OSX 10.8 I'll look into it further tomorrow.
May 04 2014
prev sibling next sibling parent "FrankLike" <1150015857 qq.com> writes:
 dub build --force --config=example
x11: ["x11"] tcltk: ["tcltk", "x11"] tkd: ["tkd", "tcltk", "x11"] Building x11 configuration "library", build type debug. Running dmd... Building tcltk configuration "library", build type debug. Running dmd... ..\..\Users\Nick\AppData\Roaming\dub\packages\tcltk-8.6.1\.dub\build\library-debug-windows-x86-dmd-C9527B3CFF40A7D16A18C46 4EF00288\tcltk.lib: Error: multiple definition of tcl_38_307: _Tcl_Main and Tcl_Main: _Tcl_Main FAIL ..\..\Users\Nick\AppData\Roaming\dub\packages\tcltk-8.6.1\.dub\build\library-debug-windows-x86-dmd-C9527B3CFF40 7D16A18C4624EF00288 tcltk staticLibrary Error executing command build: DMD compile run failed with exit code 1
Same here. It has built the tcl86.lib and tk86.lib ,but need the tcltk.lib. So Error..
May 04 2014
prev sibling parent reply "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:

 -Jsource/example/media: Use "stringImportPaths" to specify
 import paths in a compiler independent way
 Error: multiple definition of tcl_38_307: _Tcl_Main and 
 Tcl_Main: _Tcl_Main
These errors should now be fixed in Tkd v1.0.1-beta.
May 05 2014
next sibling parent "Kiith-Sa" <kiithsacmp gmail.com> writes:
On Monday, 5 May 2014 at 08:58:34 UTC, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:

 -Jsource/example/media: Use "stringImportPaths" to specify
 import paths in a compiler independent way
 Error: multiple definition of tcl_38_307: _Tcl_Main and 
 Tcl_Main: _Tcl_Main
These errors should now be fixed in Tkd v1.0.1-beta.
I don't have the time to use this right now, but I will need a working _portable_ GUI framework in a near-future project, so I just want to say that this is awesome. BTW, this is probably not a good idea in near future but it I think it would be good to have a builtin Tkinter equivalent for D. Even if it's not completely phobos-like (Tkinter is not entirely pythonic either), having a basic GUI framework ready to go without any extra setup is a huge advantage.
May 05 2014
prev sibling parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/5/2014 4:58 AM, Gary Willoughby wrote:
 On Sunday, 4 May 2014 at 19:19:57 UTC, Nick Sabalausky wrote:

 -Jsource/example/media: Use "stringImportPaths" to specify
 import paths in a compiler independent way
 Error: multiple definition of tcl_38_307: _Tcl_Main and Tcl_Main:
 _Tcl_Main
These errors should now be fixed in Tkd v1.0.1-beta.
Excellent. I just grabbed the latest, copied the dlls and setup scripts, and it works now. I did find & file a couple issues though: https://github.com/nomad-software/tcltk/issues/4 https://github.com/nomad-software/tkd/issues/11 Also, regarding DUB directory copying for the tcl init scripts, the docs mention a "postBuildCommands" which I would think could be used for that purpose (or for pretty much anything else).
May 05 2014
next sibling parent "Gary Willoughby" <dev nomad.so> writes:
On Monday, 5 May 2014 at 16:17:34 UTC, Nick Sabalausky wrote:
 Excellent. I just grabbed the latest, copied the dlls and setup 
 scripts, and it works now.

 I did find & file a couple issues though:
 https://github.com/nomad-software/tcltk/issues/4
 https://github.com/nomad-software/tkd/issues/11
Ok, i'll take a look at these.
 Also, regarding DUB directory copying for the tcl init scripts, 
 the docs mention a "postBuildCommands" which I would think 
 could be used for that purpose (or for pretty much anything 
 else).
Yeah that's the plan but i need a nice method of referring to the output directory when used as a dependency. I've been through this with Sönke and he reckons the next version of dub will be able to do this. See: https://github.com/rejectedsoftware/dub/issues/299
May 05 2014
prev sibling parent "Gary Willoughby" <dev nomad.so> writes:
On Monday, 5 May 2014 at 16:17:34 UTC, Nick Sabalausky wrote:
 I did find & file a couple issues though:
 https://github.com/nomad-software/tcltk/issues/4
 https://github.com/nomad-software/tkd/issues/11
Fixed.
May 06 2014
prev sibling parent reply =?UTF-8?B?IlRow6lv?= Bueno" <munrek gmx.com> writes:
On Sunday, 4 May 2014 at 18:39:19 UTC, Gary Willoughby wrote:
 Strange, works fine here.
Works perfectly fine for me. ArchLinux x86_64 DMD 2.065 tk 8.6 tcl 8.6 Switching TkTheme to "clam" makes the design much more better than the default one. I quickly tried tile-qt ( and tile-gtk ) but both have some problems, I will try again as this binding seems very cool and lightweight and easy-to-use.
May 04 2014
parent =?UTF-8?B?UsOpbXkgTW91w6t6YQ==?= <remy.moueza gmail.com> writes:
tile-qt with Qt 4.8+ uses invalid pixmaps.

My fix: adding in generic/tileQt_QApp.cpp line 60, 1st line of 
TileQt_CreateQApp() :
     QApplication::setGraphicsSystem("native");

The native theme is not used on the scrollbars nor on the menus (and a 
few other widgets).


On 05/05/2014 12:03 AM, "Théo Bueno" <munrek gmx.com>" wrote:
 On Sunday, 4 May 2014 at 18:39:19 UTC, Gary Willoughby wrote:
 Strange, works fine here.
Works perfectly fine for me. ArchLinux x86_64 DMD 2.065 tk 8.6 tcl 8.6 Switching TkTheme to "clam" makes the design much more better than the default one. I quickly tried tile-qt ( and tile-gtk ) but both have some problems, I will try again as this binding seems very cool and lightweight and easy-to-use.
May 06 2014
prev sibling next sibling parent "w0rp" <devw0rp gmail.com> writes:
This looks pretty sweet. I'll have to give it a try.
May 04 2014
prev sibling next sibling parent reply "Suliman" <evermind live.ru> writes:
Am I right understand that before using Tkd I should install 
Tcl/Tk ?
I tried to build simple project with dub and got error that 
system do not have tcl86.DLL
May 06 2014
parent "Gary Willoughby" <Dev nomad.so> writes:
On Tuesday, 6 May 2014 at 07:33:55 UTC, Suliman wrote:
 Am I right understand that before using Tkd I should install 
 Tcl/Tk ?
 I tried to build simple project with dub and got error that 
 system do not have tcl86.DLL
Yes. All is explained in the dependencies section in the readme text.
May 06 2014
prev sibling next sibling parent Jordi Sayol via Digitalmars-d-announce writes:
I'm the d-apt repository maintainer <http://d-apt.sourceforge.net/>.

I find Tkd very very interesting and I want to package it for Debian like
systems.

Please contact me privately at:
g.sayol yahoo.es

Regards,
-- 
Jordi Sayol
May 06 2014
prev sibling next sibling parent reply "John Colvin" <john.loughran.colvin gmail.com> writes:
On Sunday, 4 May 2014 at 16:18:53 UTC, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd

 Overview

 Tkd is a fully cross-platform GUI toolkit based on Tcl/Tk[1]. 
 Tkd allows you to build GUI applications easily and with the 
 knowledge of a consistent, native look and feel on every 
 platform.

 Why Tcl/Tk?

 Tkd development was initiated based on the performance and 
 uptake of the Tkinter[2] toolkit distributed as a standard part 
 of the Python[3] programming language. Tkinter allows 
 developers easy access to GUI programming with very little 
 learning. Being the de facto GUI toolkit of Python has 
 introduced more developers to GUI application programming and 
 increased the popularity of the language as a whole. Tkd is an 
 attempt to provide D with the same resource.

 Supported platforms

 Windows
 Linux
 Mac OSX

 Documentation

 Full HTML documentation is available inside the repository.

 Notes

 Because Tkd is based upon Tcl/Tk and being cross-platform in 
 nature there are limitations on what can be achieved. While not 
 as comprehensive as gtkd or qtd, Tkd offers a smaller and 
 lighter alternative for quickly creating native GUI 
 applications. See the readme in the repository for more 
 detailed information.

 [1]: http://www.tcl.tk/
 [2]: https://wiki.python.org/moin/TkInter
 [3]: https://www.python.org/
What dmd frontend version are you targeting/developing with?
May 07 2014
parent reply "Gary Willoughby" <Dev nomad.so> writes:
On Wednesday, 7 May 2014 at 08:26:30 UTC, John Colvin wrote:
 What dmd frontend version are you targeting/developing with?
2.065 I'll add a note to the readme file.
May 07 2014
parent "FrankLike" <1150015857 qq.com> writes:
Hello,
Can  you   let the memory usage  below  to 3M? like the DFL?


Thank you.

Frank
May 07 2014
prev sibling next sibling parent reply "John" <john.joyus gmail.com> writes:
On Sunday, 4 May 2014 at 16:18:53 UTC, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd

 Overview

 Tkd is a fully cross-platform GUI toolkit based on Tcl/Tk[1]. 
 Tkd allows you to build GUI applications easily and with the 
 knowledge of a consistent, native look and feel on every 
 platform.
What would be the Windows executable size of a typical app or your example app using Tkd? How is the performance when compared to other GUIs like Qt or Gtk? For example, in one application, I need to dynamically create several hundred of controls at runtime. Thanks for the detailed Readme. Looks like it's ready for production.
May 07 2014
parent "Kagamin" <spam here.lot> writes:
On Thursday, 8 May 2014 at 04:46:48 UTC, John wrote:
 How is the performance when compared to other GUIs like Qt or 
 Gtk? For example, in one application, I need to dynamically 
 create several hundred of controls at runtime.
BTW, what's your use case? Nested tabbed dialog? After creation it should also resize fast, which can get problematic too.
May 11 2014
prev sibling next sibling parent reply "Stef Kariotidis" <stef.kariotidis gmail.com> writes:
Just tested on Windows and looks very good and useful, thanks!

I have one question, is there by chance a way to extend Tk in D 
in order to create a grid like widget (excel, winforms grid view 
look alike)?

If yes any hints would be much appreciated. IMHO, two widgets are 
missing in Tk-Tkinter a grid as mentioned above and a web view.

Thanks again for your efforts.

Regards,
Stef K.

On Sunday, 4 May 2014 at 16:18:53 UTC, Gary Willoughby wrote:
 Tkd v1.0.0-beta

 https://github.com/nomad-software/tkd
 http://code.dlang.org/packages/tkd

 Overview

 Tkd is a fully cross-platform GUI toolkit based on Tcl/Tk[1]. 
 Tkd allows you to build GUI applications easily and with the 
 knowledge of a consistent, native look and feel on every 
 platform.

 Why Tcl/Tk?

 Tkd development was initiated based on the performance and 
 uptake of the Tkinter[2] toolkit distributed as a standard part 
 of the Python[3] programming language. Tkinter allows 
 developers easy access to GUI programming with very little 
 learning. Being the de facto GUI toolkit of Python has 
 introduced more developers to GUI application programming and 
 increased the popularity of the language as a whole. Tkd is an 
 attempt to provide D with the same resource.

 Supported platforms

 Windows
 Linux
 Mac OSX

 Documentation

 Full HTML documentation is available inside the repository.

 Notes

 Because Tkd is based upon Tcl/Tk and being cross-platform in 
 nature there are limitations on what can be achieved. While not 
 as comprehensive as gtkd or qtd, Tkd offers a smaller and 
 lighter alternative for quickly creating native GUI 
 applications. See the readme in the repository for more 
 detailed information.

 [1]: http://www.tcl.tk/
 [2]: https://wiki.python.org/moin/TkInter
 [3]: https://www.python.org/
May 07 2014
parent reply "Gary Willoughby" <dev nomad.so> writes:
On Thursday, 8 May 2014 at 06:49:40 UTC, Stef Kariotidis wrote:
 I have one question, is there by chance a way to extend Tk in D 
 in order to create a grid like widget (excel, winforms grid 
 view look alike)?

 If yes any hints would be much appreciated. IMHO, two widgets 
 are missing in Tk-Tkinter a grid as mentioned above and a web 
 view.
These widgets are not supported in Tcl/Tk by itself but could be added at any time. The Tkinter ones (and there is many) are community written using Tkinter (in Python), Tcl or as C extensions. I guess we could do the same if there is enough demand. Tkd is not meant to be an all singing all dancing GUI toolkit (such as Gtk or Qt) but rather a simple toolkit for simple UI's. If you need something built quickly with a simple UI (a prototype perhaps) use Tkd. If you're building the next Steam or Spotify use Qt/Gtk.
May 08 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/8/2014 1:46 PM, Gary Willoughby wrote:
 If you're building the next Steam or Spotify use Qt/Gtk.
Or better yet, don't. Steam's UI is terrible. Clicking search suggestions often does nothing, the search result paging is goofy as hell and very impractical, the whole thing's absurdly sluggish, in general ignores any and all system settings, menu dropdowns open upon hover instead of click, and, oh yea, my trackpad's scrolling gestures don't even fucking work on it (they work fine on nearly anything else). That's all just off the top of my head. From what I've seen of Tk so far, Steam would have been *far* better if it had used it instead of going to the bother of reinventing everything really, really badly. (Well, at least Steam isn't all-green anymore like it used to be :/ )
May 08 2014
next sibling parent reply Ben Boeckel via Digitalmars-d-announce writes:
On Thu, May 08, 2014 at 15:41:57 -0400, Nick Sabalausky via
Digitalmars-d-announce wrote:
 Or better yet, don't. Steam's UI is terrible. Clicking search 
 suggestions often does nothing, the search result paging is goofy as 
 hell and very impractical, the whole thing's absurdly sluggish, in 
 general ignores any and all system settings, menu dropdowns open upon 
 hover instead of click, and, oh yea, my trackpad's scrolling gestures 
 don't even fucking work on it (they work fine on nearly anything else).
 
 That's all just off the top of my head. From what I've seen of Tk so 
 far, Steam would have been *far* better if it had used it instead of 
 going to the bother of reinventing everything really, really badly. 
 (Well, at least Steam isn't all-green anymore like it used to be :/ )
IIRC, Steam is a Java beast, so I wouldn't go off and blame Qt/Gtk for that. --Ben
May 08 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/8/2014 4:35 PM, Ben Boeckel via Digitalmars-d-announce wrote:
 On Thu, May 08, 2014 at 15:41:57 -0400, Nick Sabalausky via
Digitalmars-d-announce wrote:
 Or better yet, don't. Steam's UI is terrible. Clicking search
 suggestions often does nothing, the search result paging is goofy as
 hell and very impractical, the whole thing's absurdly sluggish, in
 general ignores any and all system settings, menu dropdowns open upon
 hover instead of click, and, oh yea, my trackpad's scrolling gestures
 don't even fucking work on it (they work fine on nearly anything else).

 That's all just off the top of my head. From what I've seen of Tk so
 far, Steam would have been *far* better if it had used it instead of
 going to the bother of reinventing everything really, really badly.
 (Well, at least Steam isn't all-green anymore like it used to be :/ )
IIRC, Steam is a Java beast, so I wouldn't go off and blame Qt/Gtk for that. --Ben
I wasn't trying to blame Qt/Gtk (actually, I kinda like Qt stuff - I've heard it's not technically native UI, but hell if I can actually tell the difference. They've done a damn fine job.) I was just saying Steam likely would have been better had they used something more sensible like Tk instead of going off rolling their own GUI. Qt probably would have work out alright, too. Not to say that Tk/Qt would have solved all of Steam's problems, but I imagine it would've likely been at least an improvement *even* if Tk isn't intended for non-simplistic stuff. A lot of that non-simple stuff isn't really a good idea anyway.
May 08 2014
parent Jacob Carlborg <doob me.com> writes:
On 08/05/14 22:43, Nick Sabalausky wrote:

 I wasn't trying to blame Qt/Gtk (actually, I kinda like Qt stuff - I've
 heard it's not technically native UI, but hell if I can actually tell
 the difference. They've done a damn fine job.)
I think it's quite easy to tell the difference, on OS X. But that might be a problem with the actual application, that doesn't follow OS X conventions, and not Qt itself. -- /Jacob Carlborg
May 08 2014
prev sibling parent reply =?UTF-8?B?U8O2bmtlIEx1ZHdpZw==?= <sludwig+dforum outerproduct.org> writes:
Am 08.05.2014 21:41, schrieb Nick Sabalausky:
 (...)my trackpad's scrolling gestures
 don't even fucking work on it (they work fine on nearly anything else).
To be fair, some time ago I've had the joy to try and properly support scrolling gestures properly for my UI framework and I wound up naming the window class of my windows "OperaWindowClass", because that triggers a special case path in the touchpad driver, which actually sends useful window messages. I didn't find another way to get useful data. The whole (Synaptics) driver is obviously nothing but a crapload of special case junk to make the most popular applications and controls work, because the people involved obviously don't manage to develop a standard API for pixel perfect scrolling.
May 08 2014
next sibling parent Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 5/8/2014 4:51 PM, Sönke Ludwig wrote:
 Am 08.05.2014 21:41, schrieb Nick Sabalausky:
 (...)my trackpad's scrolling gestures
 don't even fucking work on it (they work fine on nearly anything else).
To be fair, some time ago I've had the joy to try and properly support scrolling gestures properly for my UI framework and I wound up naming the window class of my windows "OperaWindowClass", because that triggers a special case path in the touchpad driver, which actually sends useful window messages. I didn't find another way to get useful data. The whole (Synaptics) driver is obviously nothing but a crapload of special case junk to make the most popular applications and controls work, because the people involved obviously don't manage to develop a standard API for pixel perfect scrolling.
Hmm, that may be so. I've yet to find one piece of OEM software that isn't (at best) barely-functional garbage. And I just noticed it apparently doesn't work in Tk even with its native controls, bizarrely enough. I honestly never would have even imagined that this stuff would actually manage to fail on native controls. It just seemed obvious that if there was anything *at all* it would work with, it would be native controls. What a mess. OTOH, as little respect as I have for OEM software, I wouldn't be surprised if their hand is somewhat forced. If they'd done it by providing an API, nobody would bother to use the API. The only right way would be to integrate with existing OS support, but if the OS doesn't already provide that (I wouldn't know whether it does), then nothing's going to get companies like MS, Apple or likely even Canonical to actually give enough of a rat's ass to pull attention away from their own internal politics and agendas. Can't let nicely working user-facing features get in the way of corporate agendas and red tape, can they? ;)
May 08 2014
prev sibling parent "Tavi Cacina" <tc test.com> writes:
On Thursday, 8 May 2014 at 20:51:17 UTC, Sönke Ludwig wrote:
 Am 08.05.2014 21:41, schrieb Nick Sabalausky:
 (...)my trackpad's scrolling gestures
 don't even fucking work on it (they work fine on nearly 
 anything else).
To be fair, some time ago I've had the joy to try and properly support scrolling gestures properly for my UI framework and I wound up naming the window class of my windows "OperaWindowClass", because that triggers a special case path in the touchpad driver, which actually sends useful window messages. I didn't find another way to get useful data. The whole (Synaptics) driver is obviously nothing but a crapload of special case junk to make the most popular applications and controls work, because the people involved obviously don't manage to develop a standard API for pixel perfect scrolling.
Now that was a surprise! I just could not understand why I receive WM_MOUSEWHEEL only with 120 as Delta, but Internet Explorer receives fine grained (ex. 24). Seting the window class name as you said, 'solves' indeed the problem!
May 09 2014
prev sibling next sibling parent reply Jordi Sayol via Digitalmars-d-announce writes:
There are new deb packages for "TkD" v1.0.3 beta, available at
<http://d-apt.sourceforge.net/>

To install:
$ sudo apt-get install libtkd-dev libtkd-doc

To compile the TkD example (static linking):
$ dmd `pkg-config --cflags --libs tkd-static`
-J/usr/share/libtkd-doc/example/media/ /usr/share/libtkd-doc/example/example.d

To compile the TkD example (shared linking):
$ dmd -release `pkg-config --cflags --libs tkd`
-J/usr/share/libtkd-doc/example/media/ /usr/share/libtkd-doc/example/example.d

Regards,
-- 
Jordi Sayol
May 10 2014
parent "Gary Willoughby" <dev nomad.so> writes:
On Saturday, 10 May 2014 at 17:44:53 UTC, Jordi Sayol via 
Digitalmars-d-announce wrote:
 There are new deb packages for "TkD" v1.0.3 beta, available at 
 <http://d-apt.sourceforge.net/>

 To install:
 $ sudo apt-get install libtkd-dev libtkd-doc

 To compile the TkD example (static linking):
 $ dmd `pkg-config --cflags --libs tkd-static` 
 -J/usr/share/libtkd-doc/example/media/ 
 /usr/share/libtkd-doc/example/example.d

 To compile the TkD example (shared linking):
 $ dmd -release `pkg-config --cflags --libs tkd` 
 -J/usr/share/libtkd-doc/example/media/ 
 /usr/share/libtkd-doc/example/example.d

 Regards,
Very nice, thanks for your hard work in doing this. Let's see if people start to use it. :)
May 10 2014
prev sibling next sibling parent reply "Kagamin" <spam here.lot> writes:
On Sunday, 4 May 2014 at 16:18:53 UTC, Gary Willoughby wrote:
 https://github.com/nomad-software/tkd
https://github.com/nomad-software/tkd/blob/master/source/tkd/element/element.d Since you allocate CommandArgs in C heap, its content is invisible to GC and will be freed - uniqueData and callback.
May 11 2014
parent reply "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 11 May 2014 at 10:16:35 UTC, Kagamin wrote:
 https://github.com/nomad-software/tkd/blob/master/source/tkd/element/element.d
 Since you allocate CommandArgs in C heap, its content is 
 invisible to GC and will be freed - uniqueData and callback.
Can you clarify what you mean here? Are you asserting i am cleaning up or i need to somewhere?
May 11 2014
parent reply "Kagamin" <spam here.lot> writes:
GC cleans up for you. Usually this won't happen because 
uniqueData is likely to be in data section and callback is likely 
to be a member of a widget used elsewhere. But if they aren't, GC 
will free them and you end up with dangling pointers in 
CommandArgs.
May 11 2014
parent reply "Gary Willoughby" <dev nomad.so> writes:
On Sunday, 11 May 2014 at 14:04:44 UTC, Kagamin wrote:
 GC cleans up for you. Usually this won't happen because 
 uniqueData is likely to be in data section and callback is 
 likely to be a member of a widget used elsewhere. But if they 
 aren't, GC will free them and you end up with dangling pointers 
 in CommandArgs.
I see. I think i have been bitten by this actually. What would be your solution?
May 11 2014
parent Jacob Carlborg <doob me.com> writes:
On 2014-05-11 19:34, Gary Willoughby wrote:

 I see. I think i have been bitten by this actually. What would be your
 solution?
Without having looked at the code, call GC.addRoot. It will make sure the GC knows about the memory even if there's no other reference to it. -- /Jacob Carlborg
May 11 2014
prev sibling parent reply "SomeRiz" <goren.ali yandex.com> writes:
Hi.

Where is the installation and using tutorial for Windows?

Thank you :)
Jun 19 2014
parent reply "Gary Willoughby" <dev nomad.so> writes:
On Thursday, 19 June 2014 at 18:10:58 UTC, SomeRiz wrote:
 Hi.

 Where is the installation and using tutorial for Windows?

 Thank you :)
https://github.com/nomad-software/tkd There is a good readme file and full HTML documentation along with examples there.
Jun 19 2014
parent reply "SomeRiz" <goren.ali yandex.com> writes:
Thanks Gary.

Very simple :)

But i have a question.

All DLL file => How can i embed main.d file?

for example:

dmd output => just, main.exe so standalone

sorry for my bad english :/
Jun 19 2014
next sibling parent reply "Kagamin" <spam here.lot> writes:
BTW, there's some info about dragondrop in tk: 
http://wiki.tcl.tk/571
Jun 19 2014
parent reply "SomeRiz" <goren.ali yandex.com> writes:
Hi Kagamin.

Visual Studio like editor for TkD :/

So, TkD widgets drag and drop for TkD form
Jun 19 2014
parent reply "Kagamin" <spam here.lot> writes:
On Thursday, 19 June 2014 at 19:24:15 UTC, SomeRiz wrote:
 Visual Studio like editor for TkD :/
Hmm... visual designers can usually build pixel-oriented GUI, tk uses layouts, which work with code a little better.
Jun 20 2014
parent reply Nick Sabalausky <SeeWebsiteToContactMe semitwist.com> writes:
On 6/20/2014 4:37 AM, Kagamin wrote:
 On Thursday, 19 June 2014 at 19:24:15 UTC, SomeRiz wrote:
 Visual Studio like editor for TkD :/
Hmm... visual designers can usually build pixel-oriented GUI, tk uses layouts, which work with code a little better.
While it's been awhile since I've used visual GUI designers much, I seem to remember them (at least the better ones anyway) being perfectly capable of doing resizable layouts. Any limitations seemed to have more to do with the widgets and GUI libs themselves rather than any inherent drawback to GUI designers in general. I seem to recall doing some resizable layouts even as far back as VB3.
Jun 20 2014
parent "Kagamin" <spam here.lot> writes:
On Friday, 20 June 2014 at 18:04:20 UTC, Nick Sabalausky wrote:
 While it's been awhile since I've used visual GUI designers 
 much, I seem to remember them (at least the better ones anyway) 
 being perfectly capable of doing resizable layouts. Any 
 limitations seemed to have more to do with the widgets and GUI 
 libs themselves rather than any inherent drawback to GUI 
 designers in general. I seem to recall doing some resizable 
 layouts even as far back as VB3.
Anchors work, because they are simple and pixel-oriented. GTK boxes have too many settings to put them into a visual designer. Specialized non-pixel-oriented layouts do work with visual designers as they don't require configuration.
Jun 23 2014
prev sibling next sibling parent "Gary Willoughby" <dev nomad.so> writes:
On Thursday, 19 June 2014 at 18:47:29 UTC, SomeRiz wrote:
 Thanks Gary.

 Very simple :)

 But i have a question.

 All DLL file => How can i embed main.d file?

 for example:

 dmd output => just, main.exe so standalone

 sorry for my bad english :/
You can't, on Windows the DLL's and library folder have to be distributed with your exe. Tkd currently uses these resources: https://github.com/nomad-software/tcltk/tree/v8.6.2/dist/ Later versions of Tkd will use other DLL's i've compiled to avoid any license issues. More information is in the readme file.
Jun 19 2014
prev sibling parent reply Jacob Carlborg <doob me.com> writes:
On 2014-06-19 20:47, SomeRiz wrote:
 Thanks Gary.

 Very simple :)

 But i have a question.

 All DLL file => How can i embed main.d file?
Use DWT [1], no additional requirements besides the system libraries ;) [1] https://github.com/d-widget-toolkit/dwt -- /Jacob Carlborg
Jun 20 2014
parent reply "ed" <gmail gmail.com> writes:
On Friday, 20 June 2014 at 18:24:49 UTC, Jacob Carlborg wrote:
 On 2014-06-19 20:47, SomeRiz wrote:
 Thanks Gary.

 Very simple :)

 But i have a question.

 All DLL file => How can i embed main.d file?
Use DWT [1], no additional requirements besides the system libraries ;) [1] https://github.com/d-widget-toolkit/dwt
But there's no 64 bit support for DWT, or am I mistaken? Cheers, ed
Jun 21 2014
parent reply Jacob Carlborg <doob me.com> writes:
On 2014-06-22 08:25, ed wrote:

 But there's no 64 bit support for DWT, or am I mistaken?
Yes, correct. Why do you need 64bit? All 64bit Windows computers can run 32bit applications. -- /Jacob Carlborg
Jun 23 2014
next sibling parent "seeker" <seeker aol.com> writes:
On Monday, 23 June 2014 at 08:10:49 UTC, Jacob Carlborg wrote:
 On 2014-06-22 08:25, ed wrote:

 But there's no 64 bit support for DWT, or am I mistaken?
Yes, correct. Why do you need 64bit? All 64bit Windows computers can run 32bit applications.
customer require it - program and all components 64bit.
Jun 23 2014
prev sibling next sibling parent "Kagamin" <spam here.lot> writes:
On Monday, 23 June 2014 at 08:10:49 UTC, Jacob Carlborg wrote:
 Yes, correct. Why do you need 64bit? All 64bit Windows 
 computers can run 32bit applications.
High memory requirements :( If you have performance problems with a (big) database, a possible solution is to cache data on the client.
Jun 23 2014
prev sibling next sibling parent "Kagamin" <spam here.lot> writes:
On Monday, 23 June 2014 at 08:10:49 UTC, Jacob Carlborg wrote:
 Yes, correct. Why do you need 64bit? All 64bit Windows 
 computers can run 32bit applications.
Also big grids; hundreds of thousands items.
Jun 23 2014
prev sibling parent reply "ed" <gmail gmail.com> writes:
On Monday, 23 June 2014 at 08:10:49 UTC, Jacob Carlborg wrote:
 On 2014-06-22 08:25, ed wrote:

 But there's no 64 bit support for DWT, or am I mistaken?
Yes, correct. Why do you need 64bit? All 64bit Windows computers can run 32bit applications.
Memory is the main reason. I have started working on a 64 bit DWT port. If anything comes of it I'll submit a PR for review. Cheers, ed
Jun 23 2014
parent reply Jacob Carlborg <doob me.com> writes:
On 2014-06-23 12:21, ed wrote:

 Memory is the main reason.
Fair enough.
 I have started working on a 64 bit DWT port. If anything comes of it
 I'll submit a PR for review.
Awesome, looking forward to it. How is it going, does it require a lot of changes? -- /Jacob Carlborg
Jun 23 2014
parent reply "ed" <growlercab gmail.com> writes:
On Monday, 23 June 2014 at 16:23:54 UTC, Jacob Carlborg wrote:
 On 2014-06-23 12:21, ed wrote:

 Memory is the main reason.
Fair enough.
 I have started working on a 64 bit DWT port. If anything comes 
 of it
 I'll submit a PR for review.
Awesome, looking forward to it. How is it going, does it require a lot of changes?
I have only just started but so far it's OK. After a quick initial investigation I do have some questions regarding API changes and what people prefer in this area. I've posted to the DWT forum. Cheers, ed
Jun 23 2014
parent reply "Jack" <Jackoz530 gmail.com> writes:
I've been using this for learning experience and tried to use 
.jpg for the Image Object in vain. Are there plans to include jpg 
support here? Or is there a workaround for that? or can I use 
other image libraries to embed it to a Label Object or Button 
Object?
Feb 06 2015
parent "Gary Willoughby" <dev nomad.so> writes:
On Saturday, 7 February 2015 at 02:00:32 UTC, Jack wrote:
 I've been using this for learning experience and tried to use 
 .jpg for the Image Object in vain. Are there plans to include 
 jpg support here? Or is there a workaround for that? or can I 
 use other image libraries to embed it to a Label Object or 
 Button Object?
Tcl/Tk only currently supports *.ppm, *.pgm, *.png and *.gif. PPM/PGM formats were deemed to obscure to support in Tkd.
Feb 15 2015