× Components and Libraries for Web Development, discussions, problems and suggestions

Important Web Browser

  • 4aiman
  • 4aiman's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Comix creator
More
10 years 4 months ago #1742 by 4aiman
Web Browser was created by 4aiman
Hello everyone!
I wonder if there anything to replace Delphi's TWebBrowser component?
I know there's html panel (all systems) and gecko engine (under win), but I would have been fine with it, if only I could:
- use embedded elements (video (let's say from youtube, for example), audio, some flash and java applets);
- use css styles;
- use javascript (not really so needed, but IE engine in Delphi can do that);
So if there any free component (maybe just for windows), that can perform all this things? And what could I do to help that component to appear in CT? I'm not so good to deal with interfaces (at least I never tried), but still, what I can do?

コンソールマニアック

Please Log in or Create an account to join the conversation.

  • Gintas
  • Gintas's Avatar
  • Offline
  • Junior Member
  • Junior Member
  • Graphics Designer/Developer
More
10 years 3 months ago #1818 by Gintas
Replied by Gintas on topic Re: Web Browser
There is some tiny library writen in C. Maybe somebody could port it since
FPC can easily link .a libs.
Tiny Browser

Please Log in or Create an account to join the conversation.

  • avra
  • Visitor
  • Visitor
10 years 3 months ago #1885 by avra
Replied by avra on topic Re: Web Browser
Search Lazarus forum. I think it had examples of embedding IE on a form.

Please Log in or Create an account to join the conversation.

  • 4aiman
  • 4aiman's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Comix creator
More
10 years 3 months ago #1892 by 4aiman
Replied by 4aiman on topic Re: Web Browser
gintasdx, thanks, I'll lok into that ;)

avraIt does. And I've already tested that. But that's not what'll work for me, 'cause to make embedded IE have alclient alignment I have to set "Fulscreen" property to true. And in that case some of the IE is "invisible". Well, if you'll try it, you'll see what I'm talking about. I still could set width and height, but that works only if fulscreen is false and in that case I end up with IE caption visible.

コンソールマニアック

Please Log in or Create an account to join the conversation.

More
10 years 3 months ago - 10 years 3 months ago #1916 by Rain
Replied by Rain on topic Re: Web Browser
Not tried, but as guesswork: Not using Fullscreen, but a Form placement with

Form1.top := -30; // mind the minus

and Form width and height according to screen ccordinates ( + 30 for height) may do the trick, simulating full screen without the side effects of fullscreen.
Last edit: 10 years 3 months ago by Rain.

Please Log in or Create an account to join the conversation.

  • 4aiman
  • 4aiman's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Comix creator
More
10 years 3 months ago #1926 by 4aiman
Replied by 4aiman on topic Re: Web Browser
Well, it works, but the system menu of IE pops when I'm press alt, so it's not a good way...
Anyway, now that's unimportant since Lazarus 1.1 has ActiveX component and a long-wated tool to import type librares!
Here's wiki article: wiki.freepascal.org/LazActiveX .
Despite I couldn't make late binding with IE to work, the EARLY binding works great (and that is the way I used to in Delphi), so IE problem (and many others) is solved.
Thanks to all who replied! ;)

コンソールマニアック

Please Log in or Create an account to join the conversation.

More
10 years 3 months ago - 10 years 3 months ago #1931 by Rain
Replied by Rain on topic Re: Web Browser
Ok, ActiveX is the best solution for the given task.

But as a general (platform independent) solution for suppressing unwanted keyboard events, this code helps:

Set in Form1 property editor: KeyPreview := True
to make the following code working:

procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
begin
if Key = 18 then Key := 0; // 18 = Alt-Key
end;
Last edit: 10 years 3 months ago by Rain.

Please Log in or Create an account to join the conversation.

  • 4aiman
  • 4aiman's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
  • Comix creator
More
10 years 3 months ago - 10 years 3 months ago #1933 by 4aiman
Replied by 4aiman on topic Re: Web Browser
I knew this trick ;)
(I'm just 1 year with lazarus, but there were 6 years with Delphi, so... )

But have you tried this code? Cause IE is very stubborn when it comes to overriding some part of his (well, I believe such a notorious browser must have a personality ))) default behaviour.

Not to mention "keypreview" intercepts far from "all" of key events. Especially when ole (or com) object is focused (like flash or that IE we're taking about). Anyway, at first I need to override alt key, then I probably begin to think of IE having some bars and trying to hide them... So, saying about system menu I was driving at impossibility to think ahead of different (pardon me, English isn't my native language) possibilities.

As for "cross-platform" term - I'm in no need of suppresing anything for platform-independent projects, 'cause if I'm gonna use smth external - I'll do it "wide & open" ;)

It's normal - when smbd use browser - just open it in the system's default one. If someone want to use pdf functional then, I believe, he (or she) not may, but must use system's default document viewer :) So, why am I bothered myself to use IE and even disturbed you? (I highly appreciate your help, really, thanks alot!)

Warning: Spoiler!

One more time - Thank You for your time! ;)

コンソールマニアック
Last edit: 10 years 3 months ago by 4aiman.

Please Log in or Create an account to join the conversation.