|
-
Aug 14th, 2000, 05:59 PM
#1
Thread Starter
Addicted Member
I have used the font MonoType Corsiva in one of my programs, which I will be deploying using the Package and Deployment Wizard. I am really paranoid that the end user will not be able to support this font, resulting in another font being substituted. This could cause all sorts of sizing problems.
Am I being over paranoid? Is there a way to package the font with the application to avoid these issues? How do I find out if this is a standard windows font or an extra?
Hope someone can help me out. Many Thanks,
Steve.
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
Aug 14th, 2000, 08:20 PM
#2
Frenzied Member
From one steve to another: you can never be too paranoid in programming. There is always 1 person where something goes wrong, and the user knows nothing about computers and can't fix it. Do everything you can to make sure it works right.
this is a good installation program (recommended by denniswrenn) http://www.jrsoftware.org
-
Aug 14th, 2000, 08:51 PM
#3
Addicted Member
I know the feeling mister! I also would like to know the answer to this question. I bet you're kind of pizzed that I didn't really supply you with any useful information but look at it this way- I moved the message up to the top.
BTW- Explain how 1 is a prime because I was always taught that 1 was a "special" number (let's face it, they're all special!) and that since it is only divisible by itself that it is not a prime.
Is it tired in here or is it just me?
Ryan Williams
-Using Vb6-
-
Aug 15th, 2000, 12:19 PM
#4
Frenzied Member
1 is divisible by 1 and itself. 
Sending this post back to the top
-
Aug 15th, 2000, 12:50 PM
#5
Fanatic Member
-
Aug 15th, 2000, 01:58 PM
#6
-
Aug 15th, 2000, 02:07 PM
#7
Frenzied Member
getting back off topic
my life depends on 1 being prime. I don't know why, thats just the way my liver works.
-
Aug 15th, 2000, 02:34 PM
#8
Lively Member
It just doesn't deserve it
I know this doesn't deserve to be back at the top but I had to put in my two pennerth. If we treat 1 as a prime our little rules of maths would break down - for instance, all numbers would have an infinite number of prime factors:
28 >> 7,2,2
would become
28 >> 7,2,2,1,1,1,1,1,1,1,1...ad infinitum - craziness
Also, surely it's illogical to say that 1 is divisible by 1 and itself. That's like saying my name is both Sam and Sam. Yet more craziness. I'm sure there are many more reasons on top of the two I have pointed out.
In short, I thoroughly recommend you look into altering your handle - if this is not possible then as of this moment you should be forever banished from the vb-world forums, as a traitor to the prime family...
-
Aug 15th, 2000, 03:49 PM
#9
Monday Morning Lunatic
on topic...off topic...on topic...off topic...on topic
Okay. Fonts. Just copying it won't help, as it needs to be entered into the registry. Check out this key: HKLM\Software\Microsoft\Windows\CurrentVersion\Fonts
Inno Setup (mentioned earlier) lets you do this.
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Aug 15th, 2000, 04:14 PM
#10
Lively Member
Maybe try this?
Presumably you could get the installation package to drop the font into the font folder and then add a routine at the beginning of your application, which, before any forms become visible to the user, enters the font information into the registry. Perhaps kickstarting the program with a Sub_Main() rather than a form would suffice. The registry's font information looks simple and replicatable enough to me. VB-world has a helpful section on registry access at http://www.vb-world.net/registry/registry2/
Is that any help?
-
Aug 15th, 2000, 04:15 PM
#11
Monday Morning Lunatic
I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
-- Linus Torvalds
-
Aug 16th, 2000, 05:50 PM
#12
Thread Starter
Addicted Member
Right, let's get this cleared up!
Let's get this whole "1 is a prime!" thing sorted out, once and for all.
Firstly, not wishing to brag, but I've just graduated in Mathematical Physics. I'm not 100% sure, but seem to remember, that by the strict definition of a prime number, 1 is not considered to be prime. I was not able to find concrete proof of this in my old text books, however. Samdv's argument is fairly convincing though, so I would go with 1 not being a prime.
So, you're probably wondering (heck! who am I kidding, no-one reall cares do they, let's be honest), "Why the incorrect handle?" Well, it comes from a joke, which I'd like to share with you, if you don't mind.
Are you sitting comfortably? Then I'll begin...
An engineer, a physicist, a mathematician and a computer programmer have all applied for the same job. Right through every stage of interviews, there was nothing what-so-ever to separate the four candidates, and so the interviewer decides to pose a tie-break question to see who gets the job. He says to the four nervous hopefulls, "Work out the first 100 prime numbers. Whoever gets the closest can have the job!"
...So, after a few hours, the four interviewees return to hand in their solutions. The engineer, after having practically worn his slide rule away to nothing, says, "Well, 1 is a prime, 3 is a prime and 5 is a prime. After that, 7 is a prime, 9 is a prime, 11 is a prime, 13 is a prime and 15 is a prime. Infact all odd numbers are prime." The engineer is escorted from the building.
Next up is the physicist. After having completed some very intricate experiments, using expensive equipment (all payed for by the tax payer), he says, "3 is a prime, 5 is a prime, 7 is a prime, 11 is a prime, 13 is a prime, 15 is a prime (to within experimental error)..." He too is shown the door.
Up steps the mathematician, who, after carrying out a complex but incredibly efficient algoithm (in his head, of course), correctly states the first 100 prime numbers.
So, it's betweem the mathematician and the computer programmer. The programmer strides confidently into the interview room and hands the interviewer a print out. He says, "I have written a program which calculates the first 100 prime numbers. Here are my results."
On the paper is printer the following:
1 is a prime
1 is a prime
1 is a prime
1 is a prime
1 is a prime...
Sorry!
I used this joke as an insult on my house mate, who was studying computer science last year. The ironic thing is, that of the two of us, I have gone into computer programming.
1 is a prime, indeed!
Thanks very much for your help with the fonts guys!
Cheers,
Steve
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
Aug 17th, 2000, 01:42 PM
#13
Thread Starter
Addicted Member
The final word!
Hope this end the debate:
one:
The number one is far more special than a prime! It is the unit (the building block) of the positive integers, hence the only integer which merits its own existence axiom in Peano's axioms. It is the only multiplicative identity (1.a = a.1 = a for all numbers a). It is the only perfect nth power for all positive integers n. It is the only positive integer with exactly one positive divisor. But it is not a prime. So why not? Below we give four answers, each more technical than its precursor.
Answer One: By definition of prime! The definition is as follows. An integer greater than one is called a prime number if its only positive divisors (factors) are one and itself. Clearly one is left out, but this does not really address the question "why?"
Answer Two: Because of the purpose of primes.
The formal notion of primes was introduced by Euclid in his study of perfect numbers (in his "geometry" classic The Elements). Euclid needed to know when an integer n factored into a product of smaller integers (a non-trivially factorization), hence he was interested in
those numbers which did not factor. Using the definition above he proved:
The Fundamental Theorem of Arithmetic:
Every positive integer greater than one can be written uniquely as a product of primes, with the prime factors in the product written in order of nondecreasing size.
Here we find the most important use of primes: they are the unique building blocks of the multiplicative group of integers. In discussion of warfare you often hear the phrase "divide and conquer." The same principle holds in mathematics. Many of the properties of an integer can be traced back to the properties of its prime divisors,
allowing us to divide the problem (literally) into smaller problems. The number one is useless in this regard because a = 1.a = 1.1.a = ... That is, divisibility by one fails to provide us any information about a.
Answer Three: Because one is a unit.
Don't go feeling sorry for one, it is part of an important class of numbers call the units (or divisors of unity). These are the elements (numbers) which have a multiplicative inverse. For example, in the
usual integers there are two units {1, -1}. If we expand our purview to include the Gaussian integers {a+bi | a, b are integers}, then we have four units {1, -1, i, -i}. In some number systems there are infinitely many units.
So indeed there was a time that many folks defined one to be a prime, but it is the importance of units in in modern mathematics that causes us to be much more careful with with the number one (and with primes).
Answer Four: By the Generalized Definition of Prime.
There was a time that many folks defined one to be a prime, but it is the importance of units and primes in in modern mathematics that causes us to be much more careful with with the number one (and with primes). When we only consider the positive integers, the role of one as a unit is blurred with its role as an identity; however, as we
look at other number rings (a technical term for systems in which we can add, subtract and multiply), we see that the class of units is of fundamental importance and they must be found before we can even define the notion of a prime. For example, here is how Borevich and Shafarevich define prime number in their classic text "Number Theory:"
An element p of the ring D, nonzero and not a unit, is called prime if it can not be decomposed into factors p=ab, neither of which is a unit in D.
Sometimes numbers with this property are called irreducible and then the name prime is reserved for those numbers which when they divide a product ab, must divide a or b (these classes are the same for the ordinary integers--but not always in more general systems). Nevertheless, the units are a necessary precursors to the primes, and one falls in the class of units, not primes.
BTW - I'm NOT changing my Handle.
Cheers,
Steve. (The 1 and only!)
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
Sep 2nd, 2001, 07:15 AM
#14
PowerPoster
So back to the important question.. who got the job?
While we are bagging comp programmers can i do one that bags economists....
A physicist, engineer and economist are stuck on a deserted island with only a palm tree (that was sort of there already) and a can of beans. They are hungry and trying to work out how to open it.
The physicist goes first and suggests that they utilise his spectacles to generate heat from sunlight and burn a hole in the lid. But the economist calls him stupid and says that the can will blow up and they will have no beans (except sandy ones)
The engineer suggest climbing the palm tree and dropping the can so that it will open on impact. Again, the economist pours scorn on this idea saying that the can will break and the beans will go everywhere.
In exasperation the physicist and chemist turn on the economist and say "well if you are so smart you tell us how to open it"
The economist says "it's easy. First, we assume that we have a can opener...."
-
Sep 2nd, 2001, 07:28 AM
#15
Thread Starter
Addicted Member
Who got the job? The Mathematician... of course!
I thought this thread had a died a death! Thanks for breathing new life into it Beachbum!
Economists..... Well, they draw nice graphs I s'pose.
Steve.
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
May 1st, 2002, 02:37 PM
#16
Member
I hereby declare the number 1 as a pineapple!
Errmm.. don't ask me to justify it.
-
May 1st, 2002, 03:36 PM
#17
Frenzied Member
Actually..........
The Toronto Maple Leafs are number 1!!!!!!
After they walk all over Ottawa they are gonna play either Montreal or Caroline in the conference finals, and as we all know, they both SUCK!!!!. So toronto will have a few problems in the finals against detroit but they will win the cup in 7 games to end a HUGE drought!!!!
Just thought I'd mention that.
-
May 1st, 2002, 03:59 PM
#18
Thread Starter
Addicted Member
I can't believe that:
1) This thread hasn't died yet!
2) It's deteriorated (from fonts and pure maths!) to sport and isomorpisms between fruit and numbers.
3) How much I've changed as a developer since I started this thread all those months ago!
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
May 1st, 2002, 04:57 PM
#19
I've always been told that a prime:
Is any number that cannot be derived by multipling two integer numbers aside from itself and 1.
So, since 1*1 is not an option, if you can show me any other multiplication that will derive '1', then I'll beleive 1 isn't a prime.
Need to re-register ASP.NET?
C:\WINNT\Microsoft.NET\Framework\v#VERSIONNUMBER#\aspnet_regiis -i
(Edit #VERSIONNUMBER# as needed - do a DIR if you don't know)
-
May 1st, 2002, 05:44 PM
#20
Thread Starter
Addicted Member
Lord Rat: Good thinking, but....
Using YOUR definition, 1 is not a prime number, since -1 and -1 are two integers that multiply to give 1. QED.
I think you should read the section entitled The Final Word - it's in this thread. It is taken from another source (not my own work!), and is therefore trustworthy?!? I don't think we need say any more on the issue - The Final Word says it all really.
The one and only Steve.
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
May 2nd, 2002, 01:35 PM
#21
Member
-
May 6th, 2002, 01:33 PM
#22
Thread Starter
Addicted Member
homncruse: I started the thread in August 2000, back in the days when I'd only just started with VB.
Maybe if we can keep bumping this thread to the top it will aquire cult status! (Glad I grabbed the name while it was free!) I can feel this thread going retro...
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
May 6th, 2002, 01:40 PM
#23
Member
Originally posted by 1 is a prime!
homncruse: I started the thread in August 2000, back in the days when I'd only just started with VB.
Maybe if we can keep bumping this thread to the top it will aquire cult status! (Glad I grabbed the name while it was free!) I can feel this thread going retro...
Wow that was like 1.5 years ago or something like that. Damn 
Glad I could revive it once again!
-
May 6th, 2002, 02:01 PM
#24
Thread Starter
Addicted Member
Sent by: Steve Barker
E-mail: [email protected]
P.S. I KNOW 1 is not a prime!
See this thread: http://forums.vb-world.net/showthread.php?threadid=26485
-
Aug 6th, 2003, 06:53 PM
#25
Member
But it did.
Now it isn't.
Whee my first post in over a year happens to be here
-
Aug 6th, 2003, 06:56 PM
#26
Originally posted by 1 is a prime!
It'll never die!
It just did.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|