Home All Groups Group Topic Archive Search About
Post Other interesting topics

Auto Spacing Labels in 2D Graph

Author
14 May 2009 12:18 AM
David
I wrote a simple graph program to use in a picturebox.

The number of plotted points may vary.

I would like to auto space the labels such that if there are 500 points the
X or Y labels are not so close together that the labels over write each
other, but if there are only 3 points then more space would appear between
the labels.   All this needs to be dependent on the PBox Scale whether Pixel
or User Defined.

-------------------------------
The variables IMHO that are available are:

1)   picturebox scale.Width

2)  iDataPts = # of data points

3)  LenAllLabels = LenAllLabels + picGraph.TextWidth(DataX(i + 1))

4)    If picGraph.TextWidth(DataX(i + 1)) > LenLongestLabel Then
            LenLongestLabel = picGraph.TextWidth(DataX(i + 1))
       End If

5) Some fudge factor for spacing

-----------------------

But not sure how one would calculate or even if on the right track?

Author
8 May 2009 9:42 PM
aushknotes
Can someone please tell me what it does for sendkeys with the following CHRs?

Chr(188)
Chr(189)
Chr(190)
Chr(191)

Many thanks!
Author
9 May 2009 3:46 AM
Nobody
"aushknotes" <aushkno***@discussions.microsoft.com> wrote in message
news:853467F9-8A4E-4618-A442-532AE33AC3C4@microsoft.com...
> Can someone please tell me what it does for sendkeys with the following
> CHRs?
>
> Chr(188)
> Chr(189)
> Chr(190)
> Chr(191)
>
> Many thanks!

Characters in the range 128 to 255 have different meaning based on the code
page of the system, so without the code page, it's impossible to tell what
characters they refer to. Call GetACP() to get the code page.
Author
9 May 2009 12:43 PM
Jason Keats
Nobody wrote:
Show quoteHide quote
> "aushknotes" <aushkno***@discussions.microsoft.com> wrote in message
> news:853467F9-8A4E-4618-A442-532AE33AC3C4@microsoft.com...
>> Can someone please tell me what it does for sendkeys with the following
>> CHRs?
>>
>> Chr(188)
>> Chr(189)
>> Chr(190)
>> Chr(191)
>>
>> Many thanks!
>
> Characters in the range 128 to 255 have different meaning based on the code
> page of the system, so without the code page, it's impossible to tell what
> characters they refer to. Call GetACP() to get the code page.
>
>

Nobody is on the ball! (I love being able to say that.)

Very recently I've had to adjust a program to handle the Japanese
version of Windows. Their default codepage did not recognise the bullets
(Chr$(149) or ChrW$(&H2022)) that I was using in various listboxes and
labels).

As he said, GetACP() allowed me to detect the codepage and make the
appropriate adjustments.

What a hassle. What took them so long to invent unicode?
Author
12 May 2009 7:45 PM
Bob O`Bob
Jason Keats wrote:
>
> What a hassle. What took them so long to invent unicode?


Cultural ignorance.  Willful ignorance, in many cases.

+ Computing tech has historically been dominated by the USA

+ Many folks here literally *don't care* that other cultures exist

+ Some of them even think that American English was spoken
   2000 years ago in the Middle East


It's hard to reach that kind of stupid.



    Bob
--
even when it comes here from Europe, with an [MVP] stamp on it.
Author
12 May 2009 8:20 PM
Tom Shelton
On 2009-05-12, Bob O`Bob <filter***@yahoogroups.com> wrote:
Show quoteHide quote
> Jason Keats wrote:
>>
>> What a hassle. What took them so long to invent unicode?
>
>
> Cultural ignorance.  Willful ignorance, in many cases.
>
> + Computing tech has historically been dominated by the USA
>
> + Many folks here literally *don't care* that other cultures exist
>
> + Some of them even think that American English was spoken
>    2000 years ago in the Middle East
>
>
> It's hard to reach that kind of stupid.
>
>
>
>     Bob

What a load of clap trap.  You know as well as I do it was the 1) low memory
conditions of early systems and 2) most systems were not connected.  There simply
wasn't a need for it in the early days of computing.  But, you know - any excuse to
dis the USA right?

--
Tom Shelton
Author
12 May 2009 8:53 PM
Karl E. Peterson
Tom Shelton wrote:
>> It's hard to reach that kind of stupid.
>
> But, you know - any excuse to dis the USA right?

Looked to me like he was "dissing" a specific segment of the USA -- namely, "that
kind of stupid" -- not the country itself.  What sort of bias leads to that
intepretation?
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
12 May 2009 9:09 PM
Tom Shelton
On 2009-05-12, Karl E. Peterson <k***@exmvps.org> wrote:
Show quoteHide quote
> Tom Shelton wrote:
>>> It's hard to reach that kind of stupid.
>>
>> But, you know - any excuse to dis the USA right?
>
> Looked to me like he was "dissing" a specific segment of the USA -- namely, "that
> kind of stupid" -- not the country itself.  What sort of bias leads to that
> intepretation?


--
Tom Shelton
Author
13 May 2009 1:30 AM
Jeremiah D. Seitz
On Tue, 12 May 2009 14:09:26 -0700, Tom Shelton
<tom_shel***@comcastXXXXXXX.net> wrote:

>On 2009-05-12, Karl E. Peterson <k***@exmvps.org> wrote:
>> Tom Shelton wrote:
>>>> It's hard to reach that kind of stupid.
>>>
>>> But, you know - any excuse to dis the USA right?
>>
>> Looked to me like he was "dissing" a specific segment of the USA -- namely, "that
>> kind of stupid" -- not the country itself.  What sort of bias leads to that
>> intepretation?

    This.


    Jeremiah D. Seitz
    Omega Techware
    http://www.omegatechware.net
Author
13 May 2009 1:40 AM
Karl E. Peterson
Jeremiah D. Seitz wrote:
>>>>> It's hard to reach that kind of stupid.
>>>>
>>>> But, you know - any excuse to dis the USA right?
>>>
>>> Looked to me like he was "dissing" a specific segment of the USA -- namely,
>>> "that
>>> kind of stupid" -- not the country itself.  What sort of bias leads to that
>>> intepretation?
>
> This.

Well yeah, it /was/ a rhetorical question, afterall.  ;-)
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
13 May 2009 4:34 AM
Jeremiah D. Seitz
On Tue, 12 May 2009 18:40:21 -0700, "Karl E. Peterson"
<k***@exmvps.org> wrote:

>Jeremiah D. Seitz wrote:
>>>>>> It's hard to reach that kind of stupid.
>>>>>
>>>>> But, you know - any excuse to dis the USA right?
>>>>
>>>> Looked to me like he was "dissing" a specific segment of the USA -- namely,
>>>> "that
>>>> kind of stupid" -- not the country itself.  What sort of bias leads to that
>>>> intepretation?
>>
>> This.
>
>Well yeah, it /was/ a rhetorical question, afterall.  ;-)

You know, it took me a little too long to get that. Time for bed.

Letterman: "So, how long have you been married?"
Celebrity: "Almost twelve years."
Letterman: "Oh, that'll change ..."

Good catch, Karl. :)

    J.
    Jeremiah D. Seitz
    Omega Techware
    http://www.omegatechware.net
Author
13 May 2009 11:13 PM
Karl E. Peterson
Jeremiah D. Seitz wrote:
> Letterman: "So, how long have you been married?"
> Celebrity: "Almost twelve years."
> Letterman: "Oh, that'll change ..."

Heh, there ya go... <g>
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
13 May 2009 1:59 PM
mayayana
>
> Well yeah, it /was/ a rhetorical question, afterall.  ;-)

  Posting no content seems to be one of Tom's most
common responses. At first I thought he had trouble
with his email program. But then he never re-posts. So
I figure that maybe he thinks we can see his glaring,
indignant stare. :)

   Not that I don't agree with Tom. The "dissing the
USA" complaint seems a bit oversensitive, but I really
can't see the logic of blaming the lack of unicode on
ignorance. That's like asking why early cars didn't
have controls for handicapped people. They were too
busy just trying to get the darned thing to work!

>
+ Many folks here literally *don't care* that other cultures exist
>

   It might be more accurate to say they don't need
to care. When you live in Rome, what goes on in
the Celtic hinterlands simply doesn't have bearing
on your life. Now we have TV and we can see that
people are starving in Africa. But it's still pretty
abstract. It doesn't affect our lives directly. And I
haven't seen anyone posting links to Peace Corps-like
signup sites. So why the morality? If they have no
bread then let them eat unicode, right?  :)
Author
13 May 2009 11:15 PM
Karl E. Peterson
mayayana wrote:
>   Not that I don't agree with Tom. The "dissing the
> USA" complaint seems a bit oversensitive, but I really
> can't see the logic of blaming the lack of unicode on
> ignorance.

I'll claim ignorance, myself, just about everytime I overlook the need for it.  It's
just not a part of my daily existence, such that I should care.

>   It might be more accurate to say they don't need to care.

Bingo.  I know I should, but...
--
..NET: It's About Trust!
http://vfred.mvps.org
Author
14 May 2009 1:02 PM
mayayana
> >   Not that I don't agree with Tom. The "dissing the
> > USA" complaint seems a bit oversensitive, but I really
> > can't see the logic of blaming the lack of unicode on
> > ignorance.
>
> I'll claim ignorance, myself, just about everytime
> I overlook the need for it.  It's
> just not a part of my daily existence, such that
> I should care.
>

   I was actually answering to the question of
why unicode wasn't invented in the beginning,
as the original standard.

   I'm with you, though, on the idea of adding
language support. I've never made a lot of money
on software. What I have made has been almost
all from Americans. And many people who speak
other languages, assuming they were going to
pay for software in the first place, are comfortable
using English-language software. I don't see where
anyone has a moral obligation to write multi-lingual
software when they're not specifically being paid
for that. But for any heart-on-the-sleeve, ethno-philic,
"world community" tripper who wants to pay I'd be
happy to design new buttons that use international
symbols. (Then again, I suppose most of those people
are using Macs.... and they only want silly software....
Never mind. :)
Author
14 May 2009 6:52 PM
Karl E. Peterson
mayayana wrote:
> symbols. (Then again, I suppose most of those people
> are using Macs.... and they only want silly software....
> Never mind. :)

<chuckle>
--
..NET: It's About Trust!
http://vfred.mvps.org