Hello, everybody. Happy to introduce my new project- 
[wNim](https://github.com/khchen/wNim).

It is a Windows GUI Framework based on my own 
[Winim](https://github.com/khchen/winim) library. I started this project 
because I wanted to test and prove the winim library. As time goes on, it is 
full featured now.

Main features are:

  * GUI controls, menus, GDI objects, device context, images, system dialogs, 
accelerators. Everything you need in Windows programming are ready to be used.
  * Easy to use and easy to learn (especially if you already familiar with 
wxPython or wxWidgets).
  * Support layout DSL (powered by Yuriy Glukhov's Kiwi constraint solving 
library).
  * Generated relative small binary (helloworld.exe in 156kb).
  * Windows XP compatible.



**Code Examples**

Basic structure: 
    
    
    import wNim
    
    let app = App()
    let frame = Frame(title="Hello World", size=(400, 300))
    
    frame.center()
    frame.show()
    app.mainLoop()
    
    
    Run

Event handler: 
    
    
    button.wEvent_Button do ():
      frame.delete()
    
    frame.wIdExit do ():
      frame.delete()
    
    frame.wEvent_Size do ():
      layout()
    
    
    Run

Layout DSL: 
    
    
    panel.layout:
      staticText:
        top = panel.top + 10
        left = panel.left + 10
      button:
        right + 10 = panel.right
        bottom + 10 = panel.bottom
    
    
    Run

**Screenshot**

More example on github webside. Feedback is welcome. Happy coding with Nim!

Reply via email to