Search found 23 matches

by ergrull0
Wed Apr 16, 2014 8:39 pm
Forum: Mac OSX
Topic: Could something like this be achieved?
Replies: 1
Views: 1434

Could something like this be achieved?

Hello guys! I'm really eager to know if a list with a bunch of custom controls like this one could be achieved with Mac as a target platform (good) or in a cross-platform way (far better :lol:).

Image

Thanks!!! :mrgreen: :mrgreen: :mrgreen:
by ergrull0
Wed Apr 09, 2014 5:34 pm
Forum: Mac OSX
Topic: RunProgram(): Weird ReadProgramString() behaviour?
Replies: 8
Views: 3972

Re: RunProgram(): Weird ReadProgramString() behaviour?

[...]The culprit for only working when compiled to x86 code is the PB compiler. PB doesn't support variable argument functions which libcurl requires[...]
So, just to clarify my mind, the problem is that the curl_easy_setopt() function requires different types of parameters (a function pointer, a ...
by ergrull0
Tue Apr 08, 2014 8:55 pm
Forum: Mac OSX
Topic: RunProgram(): Weird ReadProgramString() behaviour?
Replies: 8
Views: 3972

Re: RunProgram(): Weird ReadProgramString() behaviour?

I want to present another solution which uses libcurl.dylib and imports the required functions. Currently it only works with the PB x86 compiler and with Unicode mode disabled (the program recognizes these conditions and displays an info message). I have tested the program with OS X 10.6.8 (Snow ...
by ergrull0
Tue Apr 08, 2014 5:54 pm
Forum: Mac OSX
Topic: RunProgram(): Weird ReadProgramString() behaviour?
Replies: 8
Views: 3972

Re: RunProgram(): Weird ReadProgramString() behaviour?

Try putting a short delay in the While loop: Delay(10)

See also: http://www.purebasic.fr/english/viewtopic.php?f=3&t=56382

Nope. It didn't work. But I found what the problem was: while downloading the curl displays a string that ends with a CR only instead of a LF. I guess that ReadProgramString ...
by ergrull0
Sun Apr 06, 2014 4:24 pm
Forum: Tricks 'n' Tips
Topic: libcurl (linux,windows,MacOS) (x64 & x86)
Replies: 8
Views: 11818

Re: libcurl (linux & windows) (x64 & x86)

Is there a way to make it work with a Mac?
by ergrull0
Sat Apr 05, 2014 10:07 pm
Forum: Mac OSX
Topic: RunProgram(): Weird ReadProgramString() behaviour?
Replies: 8
Views: 3972

RunProgram(): Weird ReadProgramString() behaviour?

Hello everybody!
I'm experimenting a bit with the RunProgram() procedure and I noticed a strange behaviour with the "curl" executable. This is the code:

Process = RunProgram("curl", "http://purebasic.com/documentation/PureBasicSmall.pdf --stderr - -o PureBasicSmall.pdf",
GetTemporaryDirectory ...
by ergrull0
Thu Mar 27, 2014 8:37 pm
Forum: Mac OSX
Topic: [SOLVED] NSAlert as a sheet: How to handle the result?
Replies: 4
Views: 2710

Re: [SOLVED] NSAlert as a sheet: How to handle the result?

ok I've just finished a sort of include for creating NSAlert sheets on the fly and a test code for testing its implementation.

File: NSAlert.pbi
EnableExplicit

;--- Custom NSAlert Event Definition
Enumeration 1000
#NSAlert_Button_OK
#NSAlert_Button_Cancel
EndEnumeration ...
by ergrull0
Tue Mar 25, 2014 10:48 pm
Forum: Mac OSX
Topic: Non-Standard item in a ToolBar
Replies: 11
Views: 7726

Re: Non-Standard item in a ToolBar

Thanks again Shardik! May I ask you how do you came up with this code? I mean...what does this piece of code do and how does it work?

ProcedureC ToolBarCallback(Object.I, Selector.I, Sender.I)
Shared SegmentedControl.I

If Sender = SegmentedControl
Debug "Selected segment = " + CocoaMessage(0 ...
by ergrull0
Sun Mar 23, 2014 9:07 pm
Forum: Mac OSX
Topic: Non-Standard item in a ToolBar
Replies: 11
Views: 7726

Re: Non-Standard item in a ToolBar

You guys are really awesome! Thanks again for the Nth time!!! :P :P
What about the creation of that sort of "grouped" buttons gadget?
by ergrull0
Sat Mar 22, 2014 1:27 pm
Forum: Mac OSX
Topic: Non-Standard item in a ToolBar
Replies: 11
Views: 7726

Non-Standard item in a ToolBar

Hi all guys! It's me again! With another humble question... :oops:

Is it possible to add "non-standard" items in a toolbar using some sort of CocoaMessage() code? And how?

This is what I mean:

Image

Thanks!!! 8)
by ergrull0
Thu Mar 20, 2014 9:28 am
Forum: Coding Questions
Topic: [SOLVED] Packer compression level?
Replies: 3
Views: 1424

Re: Packer compression level?

To store, without compressing, you can use this:
EnableExplicit

UseZipPacker()

Import ""
PB_Object_IsObject(object, id)
PB_Packer_Objects
EndImport

#ZIP_CM_DEFAULT = -1
#ZIP_CM_STORE = 0

ImportC ""
zip_set_file_compression(hZip.i, index.q, comp.l, comp_flags.l = 0)
EndImport

Procedure ...
by ergrull0
Wed Mar 19, 2014 6:00 pm
Forum: Mac OSX
Topic: [SOLVED] NSAlert as a sheet: How to handle the result?
Replies: 4
Views: 2710

Re: NSAlert as a sheet: How to handle the result?

Shardik wrote:

Code: Select all

...
You're amazing!!! Thanks again! :mrgreen:
by ergrull0
Tue Mar 18, 2014 11:01 pm
Forum: Mac OSX
Topic: [SOLVED] NSAlert as a sheet: How to handle the result?
Replies: 4
Views: 2710

[SOLVED] NSAlert as a sheet: How to handle the result?

Hello guys! I would like to implement a NSAlert and showing it as a sheet but I'm stuck at this point. Take a look at this example:

OpenWindow(0, 0, 0, 480, 320, "AlertSheet Test", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
ButtonGadget(0, 10, 10, 180, 25, "Test sheet!")
Repeat
Select ...
by ergrull0
Tue Mar 18, 2014 6:30 pm
Forum: Feature Requests and Wishlists
Topic: Add compression levels to ZipPacker
Replies: 4
Views: 1572

Re: Add compression levels to ZipPacker

sartic wrote:not even one msg of support :(
I'm supporting you! :mrgreen:
by ergrull0
Sat Mar 15, 2014 3:53 pm
Forum: Coding Questions
Topic: [SOLVED] Packer compression level?
Replies: 3
Views: 1424

[SOLVED] Packer compression level?

Hi! Does anybody know how to set up the compression level when using the packer library (UseZipPacker in my case...)?

Thanks!