VB6中ssOption控件的问题:文本背景色从Win 98变为Win XP [英] Problem with ssOption control in VB6: Text background color changes from Win 98 to Win XP

查看:19
本文介绍了VB6中ssOption控件的问题:文本背景色从Win 98变为Win XP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 VB6 中使用 ssOption 控件(Sheridan 3d Option 控件).

I'm using the ssOption control (Sheridan 3d Option control) in VB6.

在 Windows 98 中,文本区域的背景颜色与选项圆周围的背景颜色相同,并且该颜色是默认的表单颜色.所以选项按钮看起来是透明的.

In Windows 98 the text area background color is the same color as the background color around the Option Circle, and that color is the default form color. So the Option button appears to be transparent.

没有背景颜色属性,在 Windows XP 上,文本区域的背景颜色与选项圆圈周围的背景颜色不同.

There is no Background color property and on Windows XP the background color of the text area is a different color from the background color around the Option circle.

关于为什么会发生这种情况的任何想法?控件的包装器在 Threed32.ocx 中,我在 Win98 和 WinXP 系统上的 Windows\system32 目录中都有相同版本的它.

Any ideas as to why this would happen? The control's wrapper is in Threed32.ocx and I have the same version of it in the Windows\system32 directory on both the Win98 and WinXP systems.

  1. 为什么它在 98 和 XP 上的表现可能不同?
  2. 对修复有什么想法吗?

推荐答案

SSOption 将其背景设置为 Windows XP 上的 Windows Button Face.这与您制作新表格时获得的背景相同.如果您想在多色表格上使用它,您将需要使用具有按钮面背景的框架或其他类型的外壳.否则使用 VB6 的选项按钮.

SSOption sets it background to the Windows Button Face on Windows XP. This the same background you get when you make a new form. You will need to use a frame or another type of enclosure that has a background of button face if you want to use it on a multi-colored form. Otherwise use VB6's Option button.

SSOption 的优点是能够以 3D 凸起或插入格式显示其文本.这确实只适用于默认按钮面颜色,这就是为什么它被硬编码到控件中的原因.It also has better formatting of the text when the option button is to the right of the text.

The advantages of the SSOption is the ability to display it's text in a 3D raised or inset format. This really only works well using the default button face color which is why it is hard coded into the control. It also has better formatting of the text when the option button is to the right of the text.

如果您不能使用封闭框架或面板,那么您有一个乏味的选择.您可以制作一个没有文本的 VB6 选项.如果您使用的是 3D 字体.然后可以使用两个标签来达到相同的效果.使底部为白色(或顶部,取决于凸起与插入)并偏移 1 个像素或 15 缇.

If you can't use a enclosing frame or panel then you have a tedious alternative. You can make an VB6 option with no text. If you are using the 3D font. Then you can use two labels to achieve the same effect. Make the bottom white (or top depending on raised vs inset) and offset by one pixel or 15 twips.

如果您将 VB6 作为 Visual Studio 6 包的一部分安装,则可以使用 ZoomIn 工具来确保它是正确的.

You can use the ZoomIn tool if you installed VB6 as part of the Visual Studio 6 package to make sure it is right.

如果您将其用于对齐.然后你可以摆弄 VB6 原生选项控件的宽度,直到它看起来正确或使选项没有文本并使用标签.

If you are using it for the Alignment. Then you can fiddle with the width of the VB6 native option control until it looks right or make the option with no text and use a label.

这篇关于VB6中ssOption控件的问题:文本背景色从Win 98变为Win XP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆