Solved

twips and pixels

Posted on 1999-01-14
4
809 Views
Last Modified: 2008-02-01
1. The help file said that twip is independent on the screen while pixel is dependent. I did a test: change the screen resolusion for the same application. For a full screen form width, both the twips and pixels were changed (both are dependet to scree?) although the rate of twips to pixel was remained to 15.
2. If we set a form's width = 9600 twips, in different computers it will remain 9600 twips and 640 pixels...I must misunderstood something!
0
Comment
Question by:learn
  • 2
4 Comments
 
LVL 10

Accepted Solution

by:
caraf_g earned 40 total points
ID: 1456315
Different screens have different values for Twips Per Pixel.

There are two values available in every VB program to find out what the actual Twips Per Pixel values are.

Screen.TwipsPerPixelX gives you the horizontal number of Twips Per Pixel
Screen.TwipsPerPixelY gives you the vertical one.

Depending on these values, the form will have different widths in pixels.

If your form is 1500 Twips wide, and your screen's TwipsPerPixelX value is 15, the form will be 100 pixels wide.

On another monitor, however, the TwipsPerPixelX value could be 12.

On that monitor, the same form with a width of 1500 twips will be 1500/12 = 125 pixels wide.
0
 

Author Comment

by:learn
ID: 1456316
But why twip is screen independent?
0
 
LVL 3

Expert Comment

by:vikiing
ID: 1456317
>But why twip is screen independent?

"Twip" stands for "Twentieth of one printer's point". There are approx. 1440 twips in a logical inch, or 567 twips in a logical centimeter; that's the length of a piece of screen measuring one inch or one centimeter when it is printed.

0
 

Author Comment

by:learn
ID: 1456318
Hi vikiing

Do you mean in any computer and any printer, we always print out one point in the printer from 20 twips in the computer?
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now