473,473 Members | 2,025 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Fitting a character on a small button

I have been trying to make a (supposedly) simple control. The control is
nothing more than a control used to select integers, I was planning on
making it a UserControl composed of a TextBox and 2 Buttons (basically like
those controls you sometimes see in Windows applications). The functionality
is obviously very simple code, and I was going to make the
increment/decrement buttons using the characters 5 and 6 in the font
Webdings. The problem occurs when I try to fit a character on a button that
is only half the height of a TextBox (about 10px). I feel like I tried every
combination of CSS properties possible, but it only seemed to want to let me
move the character up, not down. Does anyone have any ideas as to how I can
make a nice-looking good-sized button for this without using graphics? If
so, I would greatly appreciate it if you could help me out here. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/
Mar 12 '06 #1
2 1310
I'm unclear what your problem is really.

It sounds like you are using an Image button control, but you are also
talking about centering text which does not compute with me. Can you be
explicit about the button type you are using the graphic size you have, and
where the fonts fit into the equation and your stylesheet code. And the
'Exact' problem you are having.

Thanks.

--
Terry Burns
http://TrainingOn.net
"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:uL**************@tk2msftngp13.phx.gbl...
I have been trying to make a (supposedly) simple control. The control is
nothing more than a control used to select integers, I was planning on
making it a UserControl composed of a TextBox and 2 Buttons (basically like
those controls you sometimes see in Windows applications). The
functionality is obviously very simple code, and I was going to make the
increment/decrement buttons using the characters 5 and 6 in the font
Webdings. The problem occurs when I try to fit a character on a button that
is only half the height of a TextBox (about 10px). I feel like I tried
every combination of CSS properties possible, but it only seemed to want to
let me move the character up, not down. Does anyone have any ideas as to
how I can make a nice-looking good-sized button for this without using
graphics? If so, I would greatly appreciate it if you could help me out
here. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

Mar 12 '06 #2
I am not using an ImageButton, I am using a
System.Web.UI.WebControls.Button, which means that there is no graphic
involved. The most significant parts of my CSS code were the margin,
font-size, and font-family properties. My "exact" problem, as best I can
explain it, is the position of the text on the button. Because the button is
so small (I believe the size I was using was 20x10px), I am having trouble
centering the text. Because part of a character is sometimes transparent, I
am having trouble moving the character vertically down far enough. Even
though the visible part of the character is small enough, the physical size
of the character is too big.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/

"Terry Burns" <me@mine.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
I'm unclear what your problem is really.

It sounds like you are using an Image button control, but you are also
talking about centering text which does not compute with me. Can you be
explicit about the button type you are using the graphic size you have,
and where the fonts fit into the equation and your stylesheet code. And
the 'Exact' problem you are having.

Thanks.

--
Terry Burns
http://TrainingOn.net
"Nathan Sokalski" <nj********@hotmail.com> wrote in message
news:uL**************@tk2msftngp13.phx.gbl...
I have been trying to make a (supposedly) simple control. The control is
nothing more than a control used to select integers, I was planning on
making it a UserControl composed of a TextBox and 2 Buttons (basically
like those controls you sometimes see in Windows applications). The
functionality is obviously very simple code, and I was going to make the
increment/decrement buttons using the characters 5 and 6 in the font
Webdings. The problem occurs when I try to fit a character on a button
that is only half the height of a TextBox (about 10px). I feel like I
tried every combination of CSS properties possible, but it only seemed to
want to let me move the character up, not down. Does anyone have any ideas
as to how I can make a nice-looking good-sized button for this without
using graphics? If so, I would greatly appreciate it if you could help me
out here. Thanks.
--
Nathan Sokalski
nj********@hotmail.com
http://www.nathansokalski.com/


Mar 12 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Grant Edwards | last post by:
I'm looking for a surface fitting library for Python. Something like the least-squares module in scientific python, except I want to fit a surface (z = f(x,y)) instead of a curve (y = f(x)). ...
38
by: Haines Brown | last post by:
I'm having trouble finding the character entity for the French abbreviation for "number" (capital N followed by a small supercript o, period). My references are not listing it. Where would I...
1
by: Marek Mänd | last post by:
<q cite="http://www.president.ee/est/ametitegevus/?gid=10628"> Kelleltki ei tohi veendumuste pärast võtta Eesti kodakondsust. </q><span class="quotereference">(Eesti Vabariigi põhiseadus, II...
7
by: Mark | last post by:
Hi... I've been doing a lot of work both creating and consuming web services, and I notice there seems to be a discontinuity between a number of the different cogs in the wheel centering around...
37
by: chandy | last post by:
Hi, I have an Html document that declares that it uses the utf-8 character set. As this document is editable via a web interface I need to make sure than high-ascii characters that may be...
18
by: james | last post by:
Hi, I am loading a CSV file ( Comma Seperated Value) into a Richtext box. I have a routine that splits the data up when it hits the "," and then copies the results into a listbox. The data also...
2
by: Nathan Sokalski | last post by:
I have been trying to make a (supposedly) simple control. The control is nothing more than a control used to select integers, I was planning on making it a UserControl composed of a TextBox and 2...
1
by: saudepp | last post by:
Hi php pros, I have an array containing n numbers and want to fit them to e.g. a polynomial function f(x), x=1...n. Is there a php script / library for doing that? I basically wish to do...
0
by: CO2 | last post by:
And here is my second problem while converting webpages to pdf: Scaling large images to fit to the page. I was using the follwing code to scale the images: <fo:external-graphic src="{@src}"...
4
by: Evelien | last post by:
Dear python-users, I am trying to do a non-linear least squares fitting. Maybe trying is not the best word, as I already succeeded in that. At the moment I am using leastSquaresFit from...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.