I am about to finish my work on a browser class for MacOSX which is quite nice & powerful. I’ve developed it
by using overlapping controls such as arrows canvas and container controls for scrolling items:
Base Layer: Container Control - does the background
Browser Layer: Used for embedded items to scroll
Arrow Canvases: Used for the Arrows (fadein/out by mouseEnter/Exit)
However, I tried running it on Window and was shocked what my class looks alike. Awfully. (Flickering,
controls do not overlap and all this kind of stuff). Of course I changed, doublebuffer=true and
eraseBackground = false resulting in a better scrolling but at the cost of transparency.
Well, after reading some posts, I could get to understand that overlapping is a no go anyway so I am
wondering how I can get the same results for windows at all?
Drawing it all in a canvas won’t work either as the embedded controls overwrite everything after a “Scroll” call.
Any suggestions from some more experienced developers ?
Now I see why you are asking in another thread about license protection
Maybe you should release first for Mac only, while you figure out what may be done in Windows.
There are inherent limits to the Windows platform that cannot be overcome, such as flicker, as well as Xojo limitations. In my experience, flicker is mostly unavoidable. Coming from Mac, it may seem unbearable, but amazingly, Windows users tend to get accustomed to some level of flicker.
In my RubberViews class, it appeared very quickly that I could not in good conscience advise users to put a background image in their projects. I tried every trick I know of to use one in the demo project, until I simply gave up. Under Windows the demo does not have a background image, where in Mac it looks quite good.
Then there are the limitations in Xojo itself regarding Windows. Due to the platform, again, but fact remains. One simply cannot stack controls in Windows. Sometimes it creates flicker, sometimes strange things happen with Z-Order. For instance in one of my apps I placed a TextField under a Rectangle, and whenever the mouse passed over it, it sprung above the rectangle from behind. Basically you cannot hide a control with another. You should instead make controls invisible.
I have no idea what you are doing in your scrolling class, but you should take your time and check every aspect of the windows project until it runs satisfactorily. Also, there are several Windows developers in this forum that can give you precious indications about dos and don’ts.
Simple projects are easy to generate for Windows and Mac simultaneously. But anything a tad more complex needs to be optimized for Windows.