OK, so my A4 printer has a printable area of 2892 horizontal resolution x 4125 vertical resolution
How can I convert those numbers to match my screen resolution? Is it divide by 96 dpi?
Help!
Brian
I started answering this post several times and kept erasing it. I guess I don't know why you would need this answer. How are you going to transfer it from your screen to your printer? My screen is bigger than what my printer page would be. You will have to scale it to whatever size you need anyway.
Maybe give some more info on what you are doing. :)
Later,
Clint
Clint,
I have modified an old program called Jonz Calendar. The PDF shows January 2022 printed in landscape mode. I would like the day box divisions to reach the bottom of an A4 page, rather than be cut off short. Gives more room for my nearest and dearest to scribble in!
I can post the whole program if you want to have a mess with it
Brian
This gives you the screen dimensions if I read right.
$INCLUDE "windowssdk.inc"
OpenConsole
UINT dpiX, dpiY
dpiX = GetDeviceCaps(GetWindowDC(0), HORZSIZE)
dpiY = GetDeviceCaps(GetWindowDC(0), VERTSIZE)
print " ",dpiX," mm wide, ",dpiY," mm tall\n"
print (dpiX/25.4)," in wide, ",(dpiY/25.4)," in tall\n"
waituntil inkey$ = chr$(27)
CloseConsole
end
Later,
Clint
Try this one.
$INCLUDE "windowssdk.inc"
OpenConsole
UINT dpiX, dpiY
dpiX = GetDeviceCaps(GetWindowDC(0), HORZSIZE)
dpiY = GetDeviceCaps(GetWindowDC(0), VERTSIZE)
print " ",dpiX," mm wide, ",dpiY," mm tall\n"
print (dpiX/25.4)," in wide, ",(dpiY/25.4)," in tall\n"
dpiX = GetDeviceCaps(GetWindowDC(0), LOGPIXELSX)
dpiY = GetDeviceCaps(GetWindowDC(0), LOGPIXELSY)
print " ",dpiX," pixels per inch wide , ",dpiY," pixels per in tall\n"
waituntil inkey$ = chr$(27)
CloseConsole
end
Later,
Clint
Clint,
I'm getting this error when compiling:
Compiling Resources...
No Errors
Compiling...
screen dimensions.iwb
Linking...
IWBasic Linker v1.11 Copyright © 2011 Ionic Wind Software
Unresolved external _window_list
Error: C:\IWBDev3\libs\iwbstd.lib\createdialog.o - Unresolved extern _window_list
Error(s) in linking c:\iwbdev3\projects\calendar\screen dimensions.exe
It has to be compiled as a windows program, not a console. I've never figured out why.
Well, that fixed it, thank you. Now I need to get the thinking cap on
Brian