Recent

Author Topic: Creating applications without conventional frame nor buttons  (Read 13982 times)

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Creating applications without conventional frame nor buttons
« on: September 27, 2016, 04:34:20 am »
Hello, my first post here.

I'm an ex-VB6er and a scripter in Javascript but most of all I am a graphic designer. I create non-windowed apps like those demonstrated below.

I am specifically looking to create non-windowed apps with fully transparent backgrounds. If Lazarus cannot do this easily then it isn't the tool for me.

Forgive me but I do not know how to insert images into posts so you'll just have to look at these links for images of the type of apps I create:
 
Note these are all PNGs without backgrounds but they are the actual apps with no embellishment.

Firstly, this is my timekeeper orrery:
http://lightquick.co.uk/images/stories/wotw-clock-big-work04.png

This is the same orrery on the desktop showing you the transparent background
http://lightquick.co.uk/images/stories/orrery-desktop-500.jpg

This is my clock/calendar/time machine...
http://lightquick.co.uk/images/stories/steampunk-calendar2.png

This is the GPU/CPU temperature gauge:
http://lightquick.co.uk/images/stories/cpu-gpu-thermometers.png

And my weather gauge:
http://lightquick.co.uk/images/stories/weather-widget500.png

Finally my media player (this is an animated GIF image)
http://i.imgur.com/nrm2QvB.gif

These are javascript/XML apps using rich and unconventional design elements to create working apps that do not fit the Apple/Microshite(sic) paradigm. They are deliberately skeumorphic and designed to be interesting to explore. If you don't like them I understand entirely.

All these apps can be placed on the desktop of a windows system and there are no Windowed elements whatsoever.

They can all be found here:
http://lightquick.co.uk/steampunk-widgets.html?Itemid=264

What I'd like to explore is:

a. how to place images in a post on this forum
b. whether Lazarus is useful for applications like this, please confirm?
c. if it is only achievable via windows API calls then I respectfully ask are there any examples that I can see that actually function in the same way?


« Last Edit: September 27, 2016, 04:52:58 am by yereverluvinunclebert »

Handoko

  • Hero Member
  • *****
  • Posts: 5131
  • My goal: build my own game engine using Lazarus
Re: Creating applications without conventional frame nor buttons
« Reply #1 on: September 27, 2016, 05:32:38 am »
Welcome to this forum.

I can answer some of your questions.

a. how to place images in a post on this forum

Click the "+" button, then there will be attachment option show up. Please see the image I uploaded.

b. whether Lazarus is useful for applications like this, please confirm?

It should be able, one of the possible option is using BGRABitmap. More info:
http://forum.lazarus.freepascal.org/index.php?topic=34038.0

c. if it is only achievable via windows API calls then I respectfully ask are there any examples that I can see that actually function in the same way?

I can't answer this one. But I suggest not to use WinApi because it will make it not able to compile to run on other OSes.

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #2 on: September 27, 2016, 05:59:54 am »
Thankyou for that, I'll take the liberty of adding those images to my next post.

Leledumbo

  • Hero Member
  • *****
  • Posts: 8747
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Creating applications without conventional frame nor buttons
« Reply #3 on: September 27, 2016, 08:53:32 am »
As I read your page, you seem to be using QML. Well, using Lazarus won't be as easy as that, as it's not that declarative. The drawing must be done from code, unless you write a component that automates it somehow.

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #4 on: September 27, 2016, 10:25:13 am »
Hmmm, yes I appreciate what you are saying.

I'm only using QML for one of the apps. the others are all using javascript and XML, not a lot of difference.

I want simply to be able to declare discrete image objects, attach code to them via events (onMouseDrag &c) and call functions to animate or change images.

I guessed that Lazarus might not be a good starting point. I have code already extant and I simply want to be able to convert said code to another engine. I have VB6 skills and just want to find a new environment where my skills in non-windowed desktop apps can be put to good use.

Two of my mini-apps are pictured here: (if I have done the attachment thing correctly).


yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #5 on: September 27, 2016, 10:25:40 am »
and this...

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11383
  • FPC developer.
Re: Creating applications without conventional frame nor buttons
« Reply #6 on: September 27, 2016, 10:40:23 am »
Afaik on windows  you can kill the app window by overriding createparams (see various Delphi sources)

However that then still is a rectangle, I never tried to make a blob shaped app. I don't know how it works, maybe by painting part of the window transparent?

mig-31

  • Sr. Member
  • ****
  • Posts: 305
Re: Creating applications without conventional frame nor buttons
« Reply #7 on: September 27, 2016, 12:04:56 pm »
I'm only using QML for one of the apps. the others are all using javascript and XML, not a lot of difference.

It is possible using QML under Windows, because it primary using under Unix/Linux with KDE for mini-desktop app?
Lazarus 2.2.6 - OpenSuse Leap 15.4, Mageia 8, CentOS 7

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #8 on: September 27, 2016, 08:59:54 pm »
I'm only using QML for one of the apps. the others are all using javascript and XML, not a lot of difference.

It is possible using QML under Windows, because it primary using under Unix/Linux with KDE for mini-desktop app?

All the other apps are pure javascript and it is those that I want to convert. A QML app on linux is known as a plasmoid and requires KDE desktop to run. The KDE desktop is not available in a stable and supported form on Windows.

QT and QML all seem a bit of a bodge, coming from the Linux arena. All the documentation is a bit jumbled and hazy and I don't fancy rewriting all my apps and finding out that the platform is unsupported in a year or so's time. They have just announced that version 5 of the KDE desktop no longer supports javascript. I had planned to convert to it up to that point but I have now abandoned that idea as I have to chuck all my javascript away and rewrite my usable code... In that case I might as well look around for a more stable platform - and here I am...

Leledumbo

  • Hero Member
  • *****
  • Posts: 8747
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: Creating applications without conventional frame nor buttons
« Reply #9 on: September 27, 2016, 09:34:03 pm »
I want simply to be able to declare discrete image objects, attach code to them via events (onMouseDrag &c) and call functions to animate or change images.
Simply possible.
I guessed that Lazarus might not be a good starting point. I have code already extant and I simply want to be able to convert said code to another engine. I have VB6 skills and just want to find a new environment where my skills in non-windowed desktop apps can be put to good use.
I won't say it's impossible, but surely requires effort and probably a shift in paradigm. If you use JavaScript to handle the event logic with XML to describe the layout, that's pretty much the same with LCL events and .lfm. Alternatively, there's a proven example using Cross Codebot library, however it's a fully handcoded application.

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #10 on: September 27, 2016, 11:33:15 pm »
First class response and an example too. It is certainly worth looking into.

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #11 on: October 12, 2016, 06:15:48 pm »
I've had a look and although it is definitely possible, it seems that I would have to code reams of code to provide the same level of functionality that javascript gives me with the additional graphics capability provided by the Konfabulator API.

Lazarus can do it but whether I could do it with Lazarus is another point altogether.

RAW

  • Hero Member
  • *****
  • Posts: 868
Re: Creating applications without conventional frame nor buttons
« Reply #12 on: October 12, 2016, 08:53:30 pm »
@ Leledumbo:
Thanks a lot...
I've never heard about "CrossCodebot" before... looks very interesting...

Some time ago I wanted to do the same thing as yereverluvinunclebert and of course it's very easy to do on a WindowsOS with the "UpdateLayeredWindow"-API. And those layered PNG-Windows do have a very small RAM-Fingerprint (at least with D7...). But when it comes to animation, then even with the best Windows-Timer I've ever seen (old MultiMediaTimer) it looks not good enough compared with an OpenGL-Window (for example scrolling text or something like that). On the other hand it depends totally on what type of animation is needed and I've never tried to use a MicroSeconds-Timer.

But I've never seen an example with OpenGL doing the same thing (normally every OpenGL-Window is a rectangle and I'm not sure if it's a good idea to use the whole screen as window and do it like that). I saw some examples but without AA and without semi-transparent pixels.

So maybe Direct2D is the answer... (I've never used D2D directly...).
And with CrossCodebot that would be even a cross-platform solution... very interesting...
I'm curious to see how much effort is necessary for my old ideas regarding this topic. Maybe I can dig them all up...

There are so many libraries out there, it's hard to know which one is best suited for something like that. For example: BGRA-Bitmap, AllegroPAS, PascalExtended Library, Vampire Imaging Library, Graphics32, opBitmap, SDL, AggPAS, Andorra2D, ZenGL, glBitmap... and so on... And of course there are a lot of possible combinations.

Thanks again...
Windows 7 Pro (x64 Sp1) & Windows XP Pro (x86 Sp3).

yereverluvinunclebert

  • New Member
  • *
  • Posts: 11
Re: Creating applications without conventional frame nor buttons
« Reply #13 on: October 12, 2016, 10:33:23 pm »
Basically a solution in Pascal it is going to be too complicated for my needs. I require an engine that does all the hard-lifting and I already have that engine in the shape of the Yahoo widget engine. It works and it does the job. The trouble is it is unsupported and at some future point in time Microsoft will break their o/s a little bit more and it will stop working altogether. I am looking for a platform with an IDE, the capability to animate easily with transparent backgrounds and able to manipulate image objects at will.

I have VB6 and other 4GL language skills, and these should readily translate to Lazarus/Pascal, I just need my chosen environment to have that graphic 'slant' that will make coding graphical applications much easier.

It surprise me that there is nothing out there that readily will suit the bill - and believe me, I have been looking...

Okoba

  • Hero Member
  • *****
  • Posts: 528
Re: Creating applications without conventional frame nor buttons
« Reply #14 on: October 12, 2016, 10:53:53 pm »
Hi,

Very interesting tools!

You have all you need in Lazarus.
Take a look at CrossCodebot, it has animations and transparent forms and mouse monitors for other stuff.

 

TinyPortal © 2005-2018