Re: Pre-alert for kdesdk-kioslaves/Frameworks in Applications 17.04

2017-03-19 Thread Michael Pyne
On Sun, Mar 19, 2017 at 10:25:16PM -0400, Michael Pyne wrote:
> On Sun, Mar 19, 2017 at 05:23:12PM +0100, Luigi Toscano wrote:
> > Luigi Toscano ha scritto:
> > Update: Michael reviewed the 3 patches and they are merged now. The kioslave
> > work, the HTML looks correct and matches for example the output of kio_man,
> > but when loaded into Konqueror the styles and the other images (which comes
> > from other kioslaves, like help:/) are not shown. If the generated page is
> > saved and the file is loaded, they are shown. I'm puzzled and I'm not sure
> > where the problem is, probably not on the kioslave side.
> 
> I think it has something to do with the way KHTML applies CSS styles...
> if you manually replace all the help:/ links with the equivalent file://
> links then the images show up find.

Actually I spoke too soon.  If the kioslave applies this same exact
replacement (help:/ -> file://) then the generated HTML does not render
properly in Konq.  If you take the kioslave output, save it to a file,
and then load the file containing the exact output, it works fine in
Konq -- even if the CSS and  links refer to help:/ instead of
file://

Sorry for the noise but unless any KHTML experts are able to help
understand why rendering the same exact HTML as a file works, while the
same HTML from an kioslave does not, then we'll continue to see this
problem.

Regards,
 - Michael Pyne


Re: Pre-alert for kdesdk-kioslaves/Frameworks in Applications 17.04

2017-03-19 Thread Michael Pyne
On Sun, Mar 19, 2017 at 05:23:12PM +0100, Luigi Toscano wrote:
> Luigi Toscano ha scritto:
> > Hi,
> > I ported what's left of kdesdk-kioslaves (kio_perldoc) to Frameworks. There
> > are 3 pending reviews for Michael Pyne:
> > https://phabricator.kde.org/D5020
> > https://phabricator.kde.org/D5021
> > https://phabricator.kde.org/D5022
> > 
> > and if he agrees, I would like to merge frameworks into master for 17.04.
> > 
> > I'm sending out this as pre-alert. I'd like to ask an exception if it's not
> > possible to complete the reviews before the dependency freeze.
> 
> Update: Michael reviewed the 3 patches and they are merged now. The kioslave
> work, the HTML looks correct and matches for example the output of kio_man,
> but when loaded into Konqueror the styles and the other images (which comes
> from other kioslaves, like help:/) are not shown. If the generated page is
> saved and the file is loaded, they are shown. I'm puzzled and I'm not sure
> where the problem is, probably not on the kioslave side.

I think it has something to do with the way KHTML applies CSS styles...
if you manually replace all the help:/ links with the equivalent file://
links then the images show up find.

The images seem to be the only problem, the CSS itself can be loaded
fine from help:/ (as confirmed by diving into the DOM using the 'Show
DOM Tree' plugin).

If it's really a KHTML CSS bug I'm not sure how difficult it will be to
fix (might be as "simple" as fixing an image loader, but I'm not a KHTML
expert).

We use generate help:/ instead of file:// in the doc kioslaves on
purpose since it points to i18n-localized paths, but for the case of
images specifically it may be that they are all common and we can
hardcode to doc/HTML/en (or at least, that doing so would be better than
nothing).

> So, I'm open to ideas: if you think that it's fine as it is (i.e. you can show
> something, which is more than the current useless kio which only works for
> kdelibs4 applications or through kioclient(4)), then I can merge frameworks
> into master.

I'm biased but I think it's better than nothing.  These kind of features
need more/better discoverability though. :(

Regards,
 - Michael Pyne


Re: Pre-alert for kdesdk-kioslaves/Frameworks in Applications 17.04

2017-03-19 Thread Luigi Toscano
Luigi Toscano ha scritto:
> Hi,
> I ported what's left of kdesdk-kioslaves (kio_perldoc) to Frameworks. There
> are 3 pending reviews for Michael Pyne:
> https://phabricator.kde.org/D5020
> https://phabricator.kde.org/D5021
> https://phabricator.kde.org/D5022
> 
> and if he agrees, I would like to merge frameworks into master for 17.04.
> 
> I'm sending out this as pre-alert. I'd like to ask an exception if it's not
> possible to complete the reviews before the dependency freeze.

Update: Michael reviewed the 3 patches and they are merged now. The kioslave
work, the HTML looks correct and matches for example the output of kio_man,
but when loaded into Konqueror the styles and the other images (which comes
from other kioslaves, like help:/) are not shown. If the generated page is
saved and the file is loaded, they are shown. I'm puzzled and I'm not sure
where the problem is, probably not on the kioslave side.

So, I'm open to ideas: if you think that it's fine as it is (i.e. you can show
something, which is more than the current useless kio which only works for
kdelibs4 applications or through kioclient(4)), then I can merge frameworks
into master.

If you are going to test this, you need to force KHTML, as WebEnginePart does
not work with the kio_*, see:
https://bugs.kde.org/show_bug.cgi?id=377084

Ciao
-- 
Luigi