Author Topic: OSX  (Read 25241 times)

Offline AIR

  • BASIC Developer
  • Posts: 932
  • Coder
Re: OSX
« Reply #45 on: July 14, 2015, 07:14:09 PM »
Hi Armando,

Long time no see indeed. :)


1. Why does the dialog widget remain unimplemented?

2. Do you plan to extend the library's common dialog palette any further?

1. On the ToDo list

2. What did you have in mind? 

Mike Lobanovsky

  • Guest
Re: OSX
« Reply #46 on: July 15, 2015, 01:58:39 AM »
Thanks for the feedback, AIR.

I meant more common dialogs like Color Dialog, Find Dialog, Replace Dialog etc. if available under Mac OSX. Also, I saw a couple of functions related to File Open/Save As functionality in the /Platform subfolder IIRC but I don't see the corresponding widgets on the list.

Offline AIR

  • BASIC Developer
  • Posts: 932
  • Coder
Re: OSX
« Reply #47 on: July 15, 2015, 07:24:56 PM »
Thanks for the feedback, AIR.

I meant more common dialogs like Color Dialog, Find Dialog, Replace Dialog etc. if available under Mac OSX. Also, I saw a couple of functions related to File Open/Save As functionality in the /Platform subfolder IIRC but I don't see the corresponding widgets on the list.

Color Dialog is something I could do, since the Cocoa Framework has that.  Find/Replace dialogs are custom windows displayed modally or in a sheet.

Open/Save is something I did a while ago, guess I forgot to update the widget list.

I've implemented Alert dialogs, see the test2.bas in the mbc folder to see how it's called/used (that example uses the old layout system, too lazy to redo it!).  Right now dialogs have hard-coded "Ok" and "Cancel" buttons, will add support for customized labels and more buttons on dialogs in a day or so.

AIR.

Offline John

  • Forum Support / SB Dev
  • Posts: 3598
    • ScriptBasic Open Source Project
Re: OSX
« Reply #48 on: July 15, 2015, 09:45:11 PM »
Great stuff!

Curious. Would SB be able to use your library on OSX?

Secondly, have you looked at Swift?
« Last Edit: July 15, 2015, 09:51:14 PM by John »

Mike Lobanovsky

  • Guest
Re: OSX
« Reply #49 on: July 16, 2015, 03:46:30 AM »
Cool!

In fact, I'm feeling rather excited about ClaroMac as #1 GUI candidate for my future work on a multi-platform BASIC/C/Asm jitter. The native OSX GUI seems to be the most mysterious part of the project, and once ClaroMac is more or less functional, it can be backported to Linux/Windows to ensure functional consistency throughout the three platforms. Granted its versatility is rather limited yet but it being written in a straight-forward procedural C as well as its small size are a definitive plus to start building my new jitter project off of.

Thanks for sharing you work, Armando!

Offline AIR

  • BASIC Developer
  • Posts: 932
  • Coder
Re: OSX
« Reply #50 on: July 16, 2015, 04:52:51 AM »
Great stuff!

Curious. Would SB be able to use your library on OSX?

It should be able to, but you'll need callback support like with just about every other GUI toolkit.

Quote
Secondly, have you looked at Swift?

Yes I have, but I don't particularly care for it.  I'm used to the square-bracket syntax of ObjectiveC.

AIR.

Offline John

  • Forum Support / SB Dev
  • Posts: 3598
    • ScriptBasic Open Source Project
Re: OSX
« Reply #51 on: July 16, 2015, 07:27:20 AM »
Quote from: Mike
Granted its versatility is rather limited yet but it being written in a straight-forward procedural C as well as its small size are a definitive plus to start building my new jitter project off of.

That's encouraging news. (C)

Mike Lobanovsky

  • Guest
Re: OSX
« Reply #52 on: August 20, 2015, 04:02:05 AM »
Hi Armando,


Quote from: AIR
I've implemented a NATIVE MacOS layout system, instead of the odd layout in the original.

Does that effectively mean that the original Win/Lin Claro's entire control layout scripting engine is disabled, null and void in ClaroMac? (its source files still seem to be present in ClaroMac/src/ tho... ::) )

Can you give me any clues as to where I can read up on common/recommended practices to implement ClaroMac-compatible user drawing? Currently, its Canvas widget seems to be nothing more than an empty stub.


TIA

Offline AIR

  • BASIC Developer
  • Posts: 932
  • Coder
Re: OSX
« Reply #53 on: August 20, 2015, 05:17:44 AM »
Hi, Mike.

The original layout engine is still in place so it can still be used.


For custom controls/drawing, take a look at: https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/CocoaDrawingGuide/DrawingEnviron/DrawingEnviron.html

Offline John

  • Forum Support / SB Dev
  • Posts: 3598
    • ScriptBasic Open Source Project
Re: OSX
« Reply #54 on: August 20, 2015, 12:40:52 PM »
Observation:

It is interesting how OSX has become a common ground for Windows and Linux developers. A dash of commercial with a pitch of open.  :)