home *** CD-ROM | disk | FTP | other *** search
- VERSION 2.00
- Begin Form TextJust
- BackColor = &H00C0C0C0&
- BorderStyle = 3 'Fixed Double
- Caption = "Text Justification"
- ClientHeight = 4020
- ClientLeft = 1095
- ClientTop = 1485
- ClientWidth = 7365
- ControlBox = 0 'False
- Height = 4425
- Left = 1035
- LinkTopic = "Form1"
- MaxButton = 0 'False
- ScaleHeight = 4020
- ScaleWidth = 7365
- Top = 1140
- Width = 7485
- Begin PictureBox Picture1
- BackColor = &H00C0C0C0&
- BorderStyle = 0 'None
- Height = 2655
- Left = 360
- ScaleHeight = 177
- ScaleMode = 3 'Pixel
- ScaleWidth = 441
- TabIndex = 1
- Top = 360
- Width = 6615
- End
- Begin CommandButton Command1
- Cancel = -1 'True
- Caption = "O &K A Y"
- Default = -1 'True
- FontBold = -1 'True
- FontItalic = 0 'False
- FontName = "MS Sans Serif"
- FontSize = 12
- FontStrikethru = 0 'False
- FontUnderline = 0 'False
- Height = 495
- Left = 360
- TabIndex = 0
- Top = 3240
- Width = 6735
- End
- Sub Command1_Click ()
- Unload Me
- End Sub
- Sub Form_Load ()
- FormCenterScreen Me
- Screen.MousePointer = 0
- End Sub
- Sub Form_Paint ()
- DoForm3D Me, sunken, 3, 0
- DoForm3D Me, raised, 1, 3
- Picture1.ScaleMode = 3
- Picture1.FontName = "Arial"
- Picture1.FontSize = 12
- Picture1.ForeColor = QBColor(0)
- msg$ = "This example demonstrates how to justify text between"
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- msg$ = "the margins of a PictureBox. The routine can"
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- msg$ = "accommodate VB forms too. This function allows you to"
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- msg$ = "present information in an eye-appealing manner."
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- Picture1.Print
- Picture1.FontName = "Times New Roman"
- Picture1.FontSize = 16
- Picture1.ForeColor = QBColor(1)
- msg$ = "Yes! With a little creativity and"
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- msg$ = "some programming expertise you could"
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- Picture1.Print
- msg$ = "even write a small word-processor yourself."
- JustifyLine Picture1.hDC, Picture1.CurrentX, Picture1.CurrentY, Picture1.ScaleWidth, msg$
- End Sub
-