LOGFONT

Everything else that doesn't fall into one of the other PB categories.
Chirantha
User
User
Posts: 54
Joined: Sat Jul 16, 2005 7:22 pm

LOGFONT

Post by Chirantha »

In http://msdn.microsoft.com/en-us/library ... S.85).aspx

There is

lfHeight = -MulDiv(PointSize, GetDeviceCaps(hDC, LOGPIXELSY), 72);

How do I make it work with Purebasic? I want to get the font size. :(
gnozal
PureBasic Expert
PureBasic Expert
Posts: 4229
Joined: Sat Apr 26, 2003 8:27 am
Location: Strasbourg / France
Contact:

Post by gnozal »

Code: Select all

lfHeight = Round(- PointSize * 72 / GetDeviceCaps_(hDC, #LOGPIXELSY), 1)
Where hDC identifies the device context, like hDC = GetDC_(WindowID(#MyWindow)) or hDC = GetDC_(GadgetID(#MyGadget)).
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).
User avatar
Fluid Byte
Addict
Addict
Posts: 2336
Joined: Fri Jul 21, 2006 4:41 am
Location: Berlin, Germany

Post by Fluid Byte »

You don't get it gonzal, do you? Why the heck you think no one answered this? Because he's being very suspicious and it seems he's also usung two accounts. In fact I already posted the answer yesterday but removed it again since I don't feel like to make a script kiddie happy anymore. So don't just serve him everything he wants on a silver tablet.
Windows 10 Pro, 64-Bit / Whose Hoff is it anyway?
gnozal
PureBasic Expert
PureBasic Expert
Posts: 4229
Joined: Sat Apr 26, 2003 8:27 am
Location: Strasbourg / France
Contact:

Post by gnozal »

Fluid Byte wrote:You don't get it gonzal, do you? Why the heck you think no one answered this?
It's gnozal ...
I didn't read the all other posts ; why so aggressive ?
Anyway :
- judging by the questions he posted, I don't think he will ever become a dangereous hacker ...
- the code I posted (font size !) isn't that dangerous, is it ?
- as for the silver tablet, the code just by itself does nothing
For free libraries and tools, visit my web site (also home of jaPBe V3 and PureFORM).
User avatar
Rook Zimbabwe
Addict
Addict
Posts: 4322
Joined: Tue Jan 02, 2007 8:16 pm
Location: Cypress TX
Contact:

Post by Rook Zimbabwe »

I say we ban both his aliases and BLOCK his webhost from connection.
Binarily speaking... it takes 10 to Tango!!!

Image
http://www.bluemesapc.com/
Sparkie
PureBatMan Forever
PureBatMan Forever
Posts: 2307
Joined: Tue Feb 10, 2004 3:07 am
Location: Ohio, USA

Post by Sparkie »

suspicious <> guilty

rumors <> facts
What goes around comes around.

PB 5.21 LTS (x86) - Windows 8.1
User avatar
Rings
Moderator
Moderator
Posts: 1435
Joined: Sat Apr 26, 2003 1:11 am

Post by Rings »

Guys, don't wonder,

as my part as a shadow mod of this board,
i have the right to delete some post.

that is what i have done with some of those from Fluid Byte,KaeruGaman.
in this topic. I don't moved them, i deleted em.

We don't like those words like F*ck here. Its a coder's place, remember.

Normaly i don't like to censore (heck i'm no chinese) ,
but some ppl post me 'rude language' via pm here.
Last edited by Rings on Thu Aug 14, 2008 2:33 pm, edited 1 time in total.
SPAMINATOR NR.1
User avatar
Rings
Moderator
Moderator
Posts: 1435
Joined: Sat Apr 26, 2003 1:11 am

Post by Rings »

Rook Zimbabwe wrote:I say we ban both his aliases and BLOCK his webhost from connection.
no, we have no 'Department of Homeland Security' here :)
and not all ppl are terrorist . (i haven 't seen any since years)
SPAMINATOR NR.1
Thalius
Enthusiast
Enthusiast
Posts: 711
Joined: Thu Jul 17, 2003 4:15 pm
Contact:

Post by Thalius »

i haven 't seen any since years
Sileeence! I keel yoo ! :lol:
"In 3D there is never enough Time to do Things right,
but there's always enough Time to make them *look* right."
"psssst! i steal signatures... don't tell anyone! ;)"
Derek
Addict
Addict
Posts: 2354
Joined: Wed Apr 07, 2004 12:51 am
Location: England

Post by Derek »

Hasn't anyone noticed that Chirantha joined in Jul 2005, so even though he hasn't posted as much as some it doesn't mean that he is just starting with PB and wants to code something nasty.
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

since Rings deleted my posting, I repeat once in a more civilized tone:

- the suspicion Chirantha uses two accounts is unfounded, it was a misunderstanding in another thread
- additionally, it is absolutely legal to use two accounts, this is a discussion forum, no browsergame

what is the reason to suspect him writing some malware?


if anyone would write a clock, may it be talking to the blind or just displaying the time for the sighted,
he may want not to show the app in the taskbar.
the windows clock, the volume control, my antivirus software - they all don't show up in the taskbar, only in the systray.

and IF you are writing software for the blind, what is so funny about wanting
to implement an emergency feature that could send a ShortMessage via Internet?
and if you want to send an SM via Internet, why don't ask how to dial a connection
for the case a not-always-connected computer is used?

you see I checked a bunch of Chirantha's posts and of the suspicions carried out agains him before posting this.


...

oh, and for a chance...
You don't get it gonzal, do you? Why the heck you think no one answered this? Because he's being very suspicious and it seems he's also usung two accounts. In fact I already posted the answer yesterday but removed it again since I don't feel like to make a script kiddie happy anymore. So don't just serve him everything he wants on a silver tablet.
this is not the fine way, so when being here to delete the following posts,
Rings, you should at least have mocked Fluid for this post.
oh... and have a nice day.
User avatar
Fluid Byte
Addict
Addict
Posts: 2336
Joined: Fri Jul 21, 2006 4:41 am
Location: Berlin, Germany

Post by Fluid Byte »

My post is pefectly legal because I have a point and don't swear like you did. No need to cry for Rings because you think you have been treaded unfair.

And now enuff' of this nonsense! :x
Windows 10 Pro, 64-Bit / Whose Hoff is it anyway?
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

your post is an impudence, that's what emberassed me,
and made me tell you that in an unpolite but very depictive language.

when you suspect (seemingly innocent) people in such a language you did,
it's in my eyes perfectly legal to tell you to shut the heck up.

and I don't "cry for Rings", I tell him, when the heck he deleted posts,
he could have made a complete job and told you not to write such crap.

and you should recognize that until now I still like you,
and that this is one reason why it embarassed me that much:
I don't like when people I like make themselves idiots.
oh... and have a nice day.
User avatar
pdwyer
Addict
Addict
Posts: 2813
Joined: Tue May 08, 2007 1:27 pm
Location: Chiba, Japan

Post by pdwyer »

Fluid Byte wrote:... No need to cry for Rings because you think you have been treaded unfair.
:shock:
I'm surprised he could remember the emergency number!

:mrgreen:
Paul Dwyer

“In nature, it’s not the strongest nor the most intelligent who survives. It’s the most adaptable to change” - Charles Darwin
“If you can't explain it to a six-year old you really don't understand it yourself.” - Albert Einstein
User avatar
Fluid Byte
Addict
Addict
Posts: 2336
Joined: Fri Jul 21, 2006 4:41 am
Location: Berlin, Germany

Post by Fluid Byte »

Ah yes, 0118 999 881 999 119 725 3, already forgot that one.

Reminds to watch both "The IT-Crowd" seasons again. Btw, do they plan a third season or did it already aired?
Windows 10 Pro, 64-Bit / Whose Hoff is it anyway?
Post Reply