|
Yeah, that doesn't surprise me. But how *exactly* are they doing it? Are they just DLU units? As in saying that the status bar is 12 DLU's high based on whatever the current font you've chosen to use with the status bar? Or is there some other magic behind determining the number?
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
Save an Orange - Use the VCF!
VCF Blog
|
|
|
|
|
Jim Crafton wrote: Or is there some other magic behind determining the number?
They probably used advanced copies of Cobra. It's going to solve everything don't you know.
led mike
|
|
|
|
|
Hmm, Cobra, that's XML based right?
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
Save an Orange - Use the VCF!
VCF Blog
|
|
|
|
|
Someone voted your OP a 2 Although it could be a feature of the new ASP.NET site.
led mike
|
|
|
|
|
I guess I forgot add "plz must hve code in fast!" in the original query. I'll keep that in mind for the next time
¡El diablo está en mis pantalones! ¡Mire, mire!
Real Mentats use only 100% pure, unfooled around with Sapho Juice(tm)!
SELECT * FROM User WHERE Clue > 0
0 rows returned
Save an Orange - Use the VCF!
VCF Blog
|
|
|
|
|
I'm using VS 2008 C++ and when I write a file out using CStdioFile or CFile under file type I get "SQL Server Compact Edition Database File" does anyone if this is alright?
I expected to only see ".sdf" under type. Right clicking on the file and selecting properties the filename alog with the ".sdf" extension is there along with "SQL Server Compact Edition Database File". What's happening?
A C++ programming language novice, but striving to learn
|
|
|
|
|
I've come across some code that is structured like this:
do {
//stuff...
} while(FALSE);
What's the difference between that and just doing the items that are in stuff WITHOUT the do-while(FALSE) "loop"?
|
|
|
|
|
The difference is that the above code is entitled to stand on the top position of the Coding Horrors forum.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
modified on Friday, February 8, 2008 3:06 PM
|
|
|
|
|
CPallini wrote: the Coding Orrors forum.
What means "Coding Orros"? I know what Coding Oreos[^] are but never heard of Coding Orros.
led mike
|
|
|
|
|
led mike wrote: What means "Coding Orros"?
Coding Orros refers to members of a family tree: http://www.genealogytoday.com/surname/finder.mv?Surname=Orros[^] who are better at making pizza than coding. http://www.yellowbot.com/orros-pizza-grill-saint-johns-fl.html[^] although obvious to us, it was not obvious to them. After seeing the pizza examples in head-first-design-patterns, you begin to realize how they thought that any pizza maker is automatically a programmer. As you see, the results of pizza makers writing software is extra cheese in our code.
_________________________
Asu no koto o ieba, tenjo de nezumi ga warau.
Talk about things of tomorrow and the mice in the ceiling laugh. (Japanese Proverb)
|
|
|
|
|
And I even made it bold.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
CPallini wrote: And I even made it bold.
I've always said "That Pallini is nothing if not bold"
led mike
|
|
|
|
|
Maybe they were trying to exercise the compilers optimization capabilities?
led mike
|
|
|
|
|
Just figured it out.
Interspersed within the {..} are #define'd a macro (ESCAPEIF(returnvalue) calls. It's defined to 'break' if an error occurrs.
At the end of the function is the cleanup
thus:
do
{
ret = foo(); //returns a '1'
BREAKONERROR(ret);
} WHILE(FALSE);
//perform cleanup (ie: release memory where needed)
Guess I should have followed the white rabbit a little more ..or took the bluepill.
|
|
|
|
|
goto is better.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
CPallini wrote: goto is better.
Youre my HERO
codito ergo sum
|
|
|
|
|
goto is dangerous in C++ if care is not taken because jumping out of scope will NOT result in the destructors of any C++ objects in the scope.
Steve
|
|
|
|
|
C++ has try -catch blocks, usually goto is not needed.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|
|
It's better than using the ugly GOTO method. In a loop you have the option of using break and continue . In this case it's a loop to be run once, unless directed to do otherwise.
Waldermort
|
|
|
|
|
WalderM wrote: It's better than using the ugly GOTO method.
better how? If you mean more readable I would argue that at best it is indistinguishably better.
led mike
|
|
|
|
|
WalderMt's better than using the ugly GOTO method.
I agree that this code is most probably the replacement for goto , but dissagree that it is better. It is even worse, because it hides the intention.
|
|
|
|
|
After a user click, I am pulling a value from a control, converting this into a decimal value and relaying it to another control. The theory is correct, but I just cannot get my code to produce the correct value. This is the formula:
double dZoomFactor = 1 / ( 1 << ( 16 - dwId ) );
where dwId is an integer value between 1 and 16;
In theory:
dZoomFactor = 1 / ( 1 << ( 16 - 1 ) );<br />
dZoomFactor = 1 / ( 1 << 15 );<br />
dZoomFactor = 1 / 32768;<br />
dZoomFactor = 0.000030517578125;
But, the output is always a flat '0.0'. What am I missing?
Waldermort
|
|
|
|
|
double dZoomFactor = 1.0 / 32768.0;
led mike
|
|
|
|
|
That comes out as 3.0517578125000000e-005 . Wish I payed more attention to maths back in school. Right now I'm trying to find out what that e-005 means.
Waldermort
|
|
|
|
|
WalderMight now I'm trying to find out what that e-005 means.
It means 10^-5 , i.e.
3.0517578125000000e-005 = 0.000030517578125000000
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke
|
|
|
|