From: Robert on
Follow up to previous "Labels" message.

VB6 SP5

Is there any Free Labels that allow "unicode"

--
Thanks in advance
Have a Great Day
bob
robert11(a)mountaincable.net


From: mark.tunnard.jackson on
On 29 Jan, 14:03, "Robert" <rob...(a)nowhere.com> wrote:
> Follow up to previous "Labels" message.
>
> VB6 SP5
>
> Is there any Free Labels that allow "unicode"
>

Hi

If you mean you want to display characters that aren't supported in
the current code page, in short, no. The forms engine in VB6 won't
allow it.

There's a bit more here

http://groups.google.co.uk/group/microsoft.public.vb.general.discussion/browse_thread/thread/562e7fc10a49be4e/673b3e2cab6017fe?lnk=gst&q=unicode+controls#673b3e2cab6017fe

Cheers
Mark
From: expvb on
"Robert" <robert(a)nowhere.com> wrote in message
news:u0%23GbphgJHA.564(a)TK2MSFTNGP03.phx.gbl...
> Follow up to previous "Labels" message.
>
> VB6 SP5
>
> Is there any Free Labels that allow "unicode"

No, but it's very easy to duplicate a label using DrawTextW with
DT_WORDBREAK flag to simulate word-wrap. You can make your own UniLabel by
following these steps:

- Start a new Standard EXE project.
- Go to Project-->Add User Control.
- Change (Name) property to UniLabel.
- Add the code below, and change as needed.
- Close UniLabel design window.
- Notice that the Toolbox have an extra icon. Click on it and place the
UniLabel on Form1. Note that this button is grayed out if the User Control
design window is open, so make sure that it's closed.
- Add Form1 code below and run the project.

Later, instead of creating every property and method of the label manually,
let VB6 generate the code using the following method:

- Load "VB ActiveX Control Interface Wizard" Addin from the Add-Ins menu.
- Start the Add-In, and add the properties and methods that you want.

Note that the control you created does not need to be in its own OCX, it
will be compiled inside the EXE, and no one can use it except you.

' Form1 code =================

Option Explicit

Private Sub Form_Load()
UniLabel1.Caption = "Hello1 " & ChrW(&H222B) & "x" & ChrW(&H2075) & _
"dx Hello2 Hello3 Hello4 Hello5 Hello6 Hello7"
End Sub

' UniLabel User Control

Option Explicit

Private Const DT_BOTTOM = &H8
Private Const DT_CALCRECT = &H400
Private Const DT_CENTER = &H1
Private Const DT_CHARSTREAM = 4 ' Character-stream, PLP
Private Const DT_DISPFILE = 6 ' Display-file
Private Const DT_EXPANDTABS = &H40
Private Const DT_EXTERNALLEADING = &H200
Private Const DT_INTERNAL = &H1000
Private Const DT_LEFT = &H0
Private Const DT_METAFILE = 5 ' Metafile, VDM
Private Const DT_NOCLIP = &H100
Private Const DT_NOPREFIX = &H800
Private Const DT_PLOTTER = 0 ' Vector plotter
Private Const DT_RASCAMERA = 3 ' Raster camera
Private Const DT_RASDISPLAY = 1 ' Raster display
Private Const DT_RASPRINTER = 2 ' Raster printer
Private Const DT_RIGHT = &H2
Private Const DT_SINGLELINE = &H20
Private Const DT_TABSTOP = &H80
Private Const DT_TOP = &H0
Private Const DT_VCENTER = &H4
Private Const DT_WORDBREAK = &H10
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Private Declare Function DrawTextW Lib "user32" (ByVal hDC As Long, _
ByVal lpStr As Long, ByVal nCount As Long, lpRect As RECT, _
ByVal wFormat As Long) As Long

Private m_Caption As String

Public Property Get Caption() As String
Caption = m_Caption
End Property

Public Property Let Caption(ByRef s As String)
m_Caption = s
End Property

Private Sub UserControl_Paint()
Dim rec As RECT

UserControl.Font = "Tahoma"
UserControl.FontSize = 12

rec.Right = UserControl.ScaleWidth / Screen.TwipsPerPixelX
rec.Bottom = UserControl.ScaleHeight / Screen.TwipsPerPixelY
DrawTextW UserControl.hDC, StrPtr(m_Caption), Len(m_Caption), rec, _
DT_WORDBREAK

End Sub


From: expvb on
Also, if you are going to use math symbols heavily, you may want to check
TeX library, which is what Wikipedia is using:

http://en.wikipedia.org/wiki/Wikipedia:Editing_Math

http://en.wikipedia.org/wiki/TeX

It's a huge download, several hundred megabytes, many seem to use it to
write books. I am not sure if you can reduce its size. Here is one free
WYSIWYG software:

http://www.latexeditor.org/screenshots.html




From: Ken Halter on
"Robert" <robert(a)nowhere.com> wrote in message
news:u0%23GbphgJHA.564(a)TK2MSFTNGP03.phx.gbl...
> Follow up to previous "Labels" message.
>
> VB6 SP5
>
> Is there any Free Labels that allow "unicode"

The first in this list is a label control that supports unicode and a lot
more.

http://www.planetsourcecode.com/vb/scripts/BrowseCategoryOrSearchResults.asp?optSort=Alphabetical&lngWId=1&B1=Quick+Search&txtCriteria=Unicode&blnWorldDropDownUsed=TRUE&txtMaxNumberOfEntriesPerPage=10&blnResetAllVariables=TRUE