Lib package compilation error

User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

Re: Lib package compilation error

Post by Josef Templ »

Robert's arguments are convincing.

Note that BOOLEAN is used in other places in WinApi, but here the definition in
the C interfaces is different.

It seems better to undo the 'cosmetic' changes for LOGFONTA and LOGFONTW in WinApi
for the benefit of backward compatibility and a close relation with the Microsoft definitions and documentations.

- Josef
Zinn
Posts: 476
Joined: Tue Mar 25, 2014 5:56 pm
Location: Frankfurt am Main
Contact:

Re: Lib package compilation error

Post by Zinn »

Robert, what do you want?
Is there any problem to run your Lib subsystem?
This kind of stuff should be not in the application module.
The Lib subsystem must be change when you transfer it to the native Linux system (*.deb).
This kind of service should be provide via subsystem Host.
If there is any problem with the MS WinApi interface then it should be solved there.
User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

Re: Lib package compilation error

Post by Josef Templ »

After a more detailed exploration it is now clear that the changes for LOGFONTA and LOGFONTW in WinApi
were a mistake even without the Lib problem. The Lib problem helped us to see this mistake.
The changes cause more problems than they (try to) solve.

We must undo this change. Technically, it is not a big deal to undo it.
Do we all agree now that we undo these changes or do we need to vote for it?

- Josef
User avatar
Robert
Posts: 1024
Joined: Sat Sep 28, 2013 11:04 am
Location: Edinburgh, Scotland

Re: Lib package compilation error

Post by Robert »

Helmut

Lib is not a Center supported product, and so this is not the place to discuss it. You can contact me privately if you wish (but you already know what my answer will be).

Lib is being used as an example to illustrate a problem with WinApi, which is a Center supported product.

I think WinApi has two problems here:

- It is an interface to a Microsoft product, and the interface needs to be comprehensible in terms of the Microsoft documentation. The previous interface was, the new one is not, without making undocumented assumptions about the internal workings of the BlackBox compiler.

- There is a concern that WinApi might return a value other than 0 or 1, in which case the new interface is almost certainly incorrect. With the old interface it is obvious that a valid and correct BOOLEAN will be created. Even if you and I know (actually I don't) that this will never happen, someone else may still have this concern, and so will worry if the new interface is correct, and have no way to check this.
User avatar
Robert
Posts: 1024
Joined: Sat Sep 28, 2013 11:04 am
Location: Edinburgh, Scotland

Re: Lib package compilation error

Post by Robert »

The original post on this subject on the Community forum also identified that the interface to WinApi.Polygon was also changed in a way that broke backward compatibility.

I don't understand what is going on here at all. Can anyone else comment on why this was changed, and if we still think the change was a good idea?


PS - Josef refers to a 'Lib problem'. I don't see a Lib problem.
User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

Re: Lib package compilation error

Post by Josef Templ »

Robert wrote: PS - Josef refers to a 'Lib problem'. I don't see a Lib problem.
The 'Lib problem' is the Lib compilation problem, i.e. that Lib cannot be compiled any longer.
Robert, I am fully in line with you. I hope I have made this clear.

- Josef
User avatar
Josef Templ
Posts: 2047
Joined: Tue Sep 17, 2013 6:50 am

Re: Lib package compilation error

Post by Josef Templ »

Robert wrote:The original post on this subject on the Community forum also identified that the interface to WinApi.Polygon was also changed in a way that broke backward compatibility.
As far as I see the situation is different in WinApi.Polygon. Here, the change serves to align
the BB definition with the Microsoft definition, where it is defined that there is an array of POINT and not a single POINT.
There are multiple changes of this kind.

The change in 'RegisterHotKey' is may be another case for discussion.
It now uses SET instead of INTEGER.

- Josef
Ivan Denisov
Posts: 1700
Joined: Tue Sep 17, 2013 12:21 am
Location: Russia

Re: issue-#23 Lib package compilation error

Post by Ivan Denisov »

With new version there is no font styles problem, however Lib is still incompatible with Center version because of Api.Polygon.

Code: Select all

res  :=  Api.Polygon (dc, pts[0], k);
Should be replaced to:

Code: Select all

res  :=  Api.Polygon (dc, pts, k);
Ivan Denisov
Posts: 1700
Joined: Tue Sep 17, 2013 12:21 am
Location: Russia

Re: issue-#23 Lib package compilation error

Post by Ivan Denisov »

There are also some formatting problems in Docu with underlined spaces...
Attachments
underline.png
underline.png (13.03 KiB) Viewed 9731 times
User avatar
Robert
Posts: 1024
Joined: Sat Sep 28, 2013 11:04 am
Location: Edinburgh, Scotland

Re: Lib package compilation error

Post by Robert »

Robert wrote:Lib is not a Center supported product, and so this is not the place to discuss it. You can contact me privately if you wish.
We (the Center) knew when we changed the behaviour of white space underlining & strikeout that it was not fully back compatible. This is no more than a symptom of that decision.

The Api.Polygon situation has already been stated on the Forum topic (which is about Lib).

http://community.blackboxframework.org/ ... &t=94#p507


PS 1 - Is it possible to make a link to a particular posting, not just to a general topic?
PS 2 - How do you insert a bitmap (.png) into a posting?
Last edited by Robert on Mon Jun 29, 2015 9:44 am, edited 1 time in total.
Post Reply