DataControl

I have a case where I would need a datacontrol which looks like the one in Xojo and I would need to have the four eventhandlers MoveFirst, MoveLast, MovePrevious, MoveNext.

It seems to me that these events are never firing. Neither in my own tests nor in the included example project for DataControl.

Is just the example project broken, is it me who is not getting it how this is supposed to work or is this control completely broken?

I have started to create my own container control for this purpose, but as it is already there, maybe it could be fixed?

[quote=147379:@Oliver Osswald]I have a case where I would need a datacontrol which looks like the one in Xojo and I would need to have the four eventhandlers MoveFirst, MoveLast, MovePrevious, MoveNext.

It seems to me that these events are never firing. Neither in my own tests nor in the included example project for DataControl.

Is just the example project broken, is it me who is not getting it how this is supposed to work or is this control completely broken?

I have started to create my own container control for this purpose, but as it is already there, maybe it could be fixed?

[/quote]

I ended up rolling my own since I have never been impressed with the appearance of that control.

Here is a screen shot of how mine has turned out.

This is slanted towards Mac OS X FWIW.

If you need to do something like that, role your own. That way you can control the look and feel and, in general, use it the way you want. Perfect place for a container control.

Also be aware that not all databases support all of the database Move operations. Check the documentation.

Is there an opensource/free font available which has glyphs like the webdings font of Microsoft: forward, backward etc?

If I could distribute such a font with my app, then I could simply use bevelbuttons like in the screenshot below. Otherwise I have to use canvases and paint everything myself …

Is there such a free font?

[quote=147446:@Oliver Osswald]Is there an opensource/free font available which has glyphs like the webdings font of Microsoft: forward, backward etc?

If I could distribute such a font with my app, then I could simply use bevelbuttons like in the screenshot below. Otherwise I have to use canvases and paint everything myself …

Is there such a free font?

[/quote]
I would love to know that also as for my screen shot above i had to use Cocoa declares for Mac to get mine with bevel’s.

Wouldn’t an image do for each bevel button? Set the Icon property as needed.

I’m not so fond of using pictures and I already have a custom datacontrol based on canvases and pictures. It looks outdated now.

With pictures I’m running into scaling- and retina issues plus I need transparent background. This is all feasible but my last picture based datacontrol looked nice on Mavericks but now not so nice on Yosemite, plus now I need a smaller one.

Using bevelbuttons with a symbol font would be more flexible for the future and it would require less coding.

But if I am not finding a font which can be legally distributed, then I will paint those buttons myself on canvases.

Why the choice of canvas over bevelbutton? Just curious as I may not have thought through all the issues.

In some places I need a datacontrol of 18 pixels height in other places 24 pixels.

I use the canvas paint event to draw the next/previous triangles, the background according to pushed state, etc.

So then I can use this custom control and size according to my needs and the canvas based buttons will always draw crisp clear, on retina or not, 18 or 24 pixels or whatever.

I don’t see how bevelbuttons would allow me to do the same, unless I simply can use a scalable font for its caption.

Ah ya, okay - I guess I can create the button pictures on the fly and then assign it as icon to the bevelbutton… Haven’t tried that yet.

Can’t you just use Unicode? I look at Dingbats (in OS X character viewer) and see those in there (hope I get the 0 and O correct)

sign Unicode UTF8
left U+F033 EF 80 B3
right U+F034 EF 80 B4
double left U+F037 EF 80 B7
double right U+F038 EF 80 B8
Far left U+F039 EF 80 B9
Far right U+F03A EF80BA

[quote=147462:@Markus Winter]Can’t you just use Unicode? I look at Dingbats (in OS X character viewer) and see those in there (hope I get the 0 and O correct)

sign Unicode UTF8
left U+F033 EF 80 B3
right U+F034 EF 80 B4
double left U+F037 EF 80 B7
double right U+F038 EF 80 B8
Far left U+F039 EF 80 B9
Far right U+F03A EF80BA[/quote]

Sorry, I don’t know how to do that: “just use Unicode”.

Zapf Dingbats is a copyrighted font as well. Is it available on any OSX, 10.7 and newer ?

look at FontAwesome. it is an OSS font released under SIL. it can be used in both OSS and Commercial software.

Found a free font which has those symbols: http://www.fontspace.com/category/fast%20forward,rewind,symbols

FontAwesome is cool! But it is lacking the single back button (triangle left)

You can use System font with the following characters:

? ?
? ?

Source: http://character-code.com/arrows-html-codes.php

Correction: FontAwesome does have the left caret. My bad.

Unicode doesn’t help if the font can’t draw it.