code logs -> 2010 -> Tue, 09 Feb 2010< code.20100208.log - code.20100210.log >
--- Log opened Tue Feb 09 00:00:14 2010
00:07
< gnolam>
And fail of the day is "billisecond": http://msdn.microsoft.com/en-us/library/z9ah41zs.aspx
00:08
< Tarinaky>
Lol!
00:10
< gnolam>
And it's actually a double fail. Or maybe even triple.
00:10
< Tarinaky>
Heh.
00:10
< Tarinaky>
Love it.
00:10
< gnolam>
First off, that the person who wrote it doesn't know an SI prefix from a hole in the wall.
00:11
< gnolam>
Second, that since he couldn't use "nano" or "pico" like a normal person, that it's now /undefined/. There are two different definitions of "billion": 10^9 and 10^12.
00:11
< Tarinaky>
I prefer to thing that is was just a typing error caused by the person being over-worked.
00:11
<@Vornicus>
I love the second comment
00:11
<@Vornicus>
It's /not actually a billionth/
00:11
< gnolam>
That's the third fail.
00:11
<@McMartin>
Er
00:11
< gnolam>
It's actually in microseconds.
00:12
< Tarinaky>
gnolam: I think it's just a milisecond.
00:12
< Tarinaky>
Oh.
00:12
<@McMartin>
At what point do you just say "your preconceptions of what this is supposed to say is wrong"?
00:12
<@McMartin>
This is moving towards "Avatar fails so hard for being this terrible stereotype it isn't, and then being a bad example of it, look how far it is from the evil thing I claim it is at first"
00:12
< Tarinaky>
Okay. I read the rest of the page.
00:12
< Tarinaky>
I see that the person needs a slap.
00:17
< gnolam>
McMartin: ?
00:50 Derakon[AFK] is now known as Derakon
01:22 Attilla [Attilla@FBC920.58502B.4BF0F8.FCE0D3] has quit [Connection reset by peer]
01:48 Serah [Z@3A600C.A966FF.5BF32D.8E7ABA] has quit [Ping timeout: 121 seconds]
02:10
<@McMartin>
Goddamn, Qt takes forever to build.
02:42 Zed_ [Zed@Nightstar-d0088b95.or.comcast.net] has joined #code
02:43 Zed [Zed@Nightstar-d0088b95.or.comcast.net] has quit [Ping timeout: 121 seconds]
02:44 gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has quit [[NS] Quit: Z?]
03:20
< Rhamphoryncus>
"billisecond" could have been better. Could have done the "binary" form, ie 2**-30. 0.000000000931322574615478515625 of a second
03:20
<@McMartin>
That's clearly a nabisecond. =(
03:20
<@McMartin>
of all the actual words, "gibibyte" makes me the saddest
03:21
< Rhamphoryncus>
I'm saddest that people think there's a justification for defining gigabyte as 2**30 (or using gibibyte)
03:22
<@Derakon>
They're powers-of-2 fetishists.
03:22
< Rhamphoryncus>
Heh, pretty much
03:23
<@McMartin>
It's easier to remember "32-bit memory is 4GB" than it is "4.294967296 GB".
03:23
<@McMartin>
And it's because kilobytes have always been 2^10.
03:23
< Rhamphoryncus>
Easier to still to just round it off to 4 billion
03:23
<@McMartin>
I've had the distinction matter.
03:24
< Rhamphoryncus>
Guess how much ram this 8 gig box has total, as reported by the OS?
03:24
<@McMartin>
3GB.
03:24
< Rhamphoryncus>
8127733760 bytes
03:25
<@Vornicus>
That's a little short.
03:25
<@McMartin>
Some may be conflicting with I/O ports?
03:25
< Rhamphoryncus>
A good chunk of it is allocated to the onboard video card
03:25
< Rhamphoryncus>
Some goes to bios
03:25
< Rhamphoryncus>
Some might be I/O ports, dunno
03:26
< Rhamphoryncus>
The whole point of using 2**30 is that it gives you exact values, but you almost never use those exact values in practise
03:27
<@McMartin>
... You use binary bit-width limits all the fricking time.
03:27
<@McMartin>
It's what produces the limits on things like fseek.
03:28
< Rhamphoryncus>
Which limit are you referring to?
03:28
< Rhamphoryncus>
2**31-1 off a 32-bit long?
03:28
<@McMartin>
Yes
03:29
<@McMartin>
And 2**32 is also the filesize limit of a FAT32 file.
03:29
< Rhamphoryncus>
I use 2**31-1 more often. It's more exact
03:29
< Rhamphoryncus>
And that's a programmer anyway. File and memory sizes are for the user
03:30
< Rhamphoryncus>
My 2 gig flash drive has 2013200384 bytes
03:31
< Rhamphoryncus>
Hard drives, file sizes, network speed, all inexact
03:31
<@McMartin>
Er
03:32
<@McMartin>
How sure are you that that isn't "what's left after metadata"?
03:32
<@McMartin>
You don't get every byte of every disk block for your stuff, and you don't get every disk block on the disk.
03:33
< Rhamphoryncus>
It's what linux reports to me. Could be metadata, could be some low-level load-levelling. Could be bad blocks that were disabled at manufacturing. Don't know, don't care. As a user it's simply "2 gigs"
03:35
<@McMartin>
You said it was "inexact"
03:35
<@McMartin>
And at least in du, file sizes will be reported by block count, which *will* be exact
03:35
<@McMartin>
And multiples of 2^9, IIRC.
03:35
< Rhamphoryncus>
Yup. A historical, useless unit
03:36
< Rhamphoryncus>
One of the kernel API, not necessarily the filesystem
03:36
< Rhamphoryncus>
I don't care how many blocks my 2.1 gig file is
03:36
<@McMartin>
Um
03:36
<@McMartin>
You do actually care about this a lot
03:36
<@McMartin>
This is why UQM ships content zipped and keeps it zipped
03:37
< Rhamphoryncus>
Tiny files?
03:37
<@McMartin>
Because it's the difference between taking up 100MB and taking up like 4 gigs.
03:37
<@McMartin>
Yes.
03:37
< Rhamphoryncus>
That's a different problem
03:37
< Rhamphoryncus>
And some filesystems merge tiny files into a single block
03:37
< Rhamphoryncus>
Of course the metadata can still add up
03:37
<@McMartin>
Neither FAT, NTFS, nor extfs, nor the MacFS do this.
03:37
< Rhamphoryncus>
And... there's no reason that "2.1 gigs" can't be rounded up to be the actual on-disk usage, if that's what I asked for
03:38
<@McMartin>
Any decent filesystem commander will tell you both the size of the file and the size on disk.
03:38
<@Vornicus>
(MacFS is called HFS+)
03:38
< Tarinaky>
Hi. Someone here said that ncurses didn't do Unicode but it could be 'faked'.
03:38
<@McMartin>
Ah, that would be me.
03:38
< Tarinaky>
Was it McMar...
03:39
< Tarinaky>
Could you umm... specify what you meant exactly?
03:39
<@McMartin>
If you set the locale to en.UTF-8, you can start outputting UTF-8-encoded strings and they will render as extended characters.
03:39
<@McMartin>
Assuming the target terminal matches them.
03:39 * Vornicus fiddles with a bit of interface.
03:39
<@McMartin>
Not sure how to do it with Windows.
03:40
< Tarinaky>
Less interested in Windows tbh
03:42
<@Vornicus>
In 4th edition D&D, each character has a selection of skills. Many classes have "required" skills - for instance, wizards must know Arcana. Rangers (this is part of my difficulty) are required to pick at least one of the two skills Nature and Dungeoneering. Right now I do the selection thing by dropdown boxes, and disable options in the box showing Nature or Dungeoneering if only one is present.
03:45
<@McMartin>
Tarinaky: http://www.ifarchive.org/if-archive/infocom/interpreters/frotz/nfrotz-0.3.3.tgz has the code I wrote in it
03:45
<@McMartin>
Search for setlocale in curses/ux_init.c, and for os_display_char in curses/ux_text.c
03:45
<@McMartin>
It is, of course, C, but the basic principles should apply
03:46
<@McMartin>
(It's setting the locale to "whatever the terminal is" and then testing later, though, so that it can handle both UTF-8 and Latin-1 terminals)
03:47
< Rhamphoryncus>
McMartin: Btrfs, ReiserFS, Reiser4, FreeBSD UFS2 all use it.
03:47
< Tarinaky>
Right. Okay. I'll try it.
03:47
<@Vornicus>
This works fine, usually - it means that if you have both but decide to replace one with one of the other skills, you don't ever have to do more than one manipulation, and I never have to worry about getting into an invalid state. However, this interacts with another thing: races. Two races (Eladrin and Human) have an extra skill to assign. THis, again, acts pretty normally. You pick the race, another dropdown shows up, everything's und
03:47
<@Vornicus>
er control.
03:47
< Rhamphoryncus>
Not that it really matters
03:48
<@McMartin>
Tarinaky: Anyway, if you look at the ncurses header files, you'll see a bunch of stuff involving composed characters and complex glyphs and &c, and it's all commented or otherwise conditioned out so that it's never compiled and won't work
03:48
<@McMartin>
Proper ncurses wide character support is presently only existent as documentation for what it will eventually do
03:49
<@Vornicus>
...until you change /away/ from that race, wherein the extra dropdown must go away. Which brings me to the problem: what do I do when the extra dropdown contains the ranger's only required skill?
03:50
< celticminstrel>
Easiest way would be to not allow them to switch away from the race, and show an error message. :P
03:50
< Tarinaky>
McMartin: Well, that's annoying.
03:51
< Rhamphoryncus>
Less annoying is to have a sanity check and report when something is broken, rather than trying to force them
03:51
<@Derakon>
Vorn: take away one of their other skills.
03:51
<@Derakon>
And then disable all the non-Ranger skills.
03:52
< celticminstrel>
Yes, that's more or less the other option I thought of.
03:52
< Rhamphoryncus>
To be really fancy you'd keep the extra skill dropdowns when you switch, but tell the user to click a button that deletes one
04:00
< Tarinaky>
Stupid question. In standard C++ is a static variable automatically initialised?
04:03
< Tarinaky>
NM. I see how I'm meant to do it.
04:41 * Tarinaky pokes McMartin.
04:43
< Tarinaky>
http://tarinaky.pastebin.com/m6fe34ecc
04:44
< Tarinaky>
What am I doing wrong?
05:08
< Tarinaky>
Ahah! Works
05:46
< Tarinaky>
"test.cpp:8: error: too few template-parameter-lists" << Does anyone know what this error typically means?
05:47
<@McMartin>
Sounds like you referred to, say, std::vector instead of std::vector<int> or whatnot
05:49
< Tarinaky>
Nope.
05:52
< Tarinaky>
Alright. Got it working now anyway.
05:58
< celticminstrel>
Tarinaky: I'm pretty sure static variables are automatically initialized to 0 according to the C++ standard.
05:58
< celticminstrel>
Or with the default constructor.
05:59
< Tarinaky>
Apparently not :/ I managed to get it to work in the end though. Which was good.
05:59
<@Derakon>
I never assume that variables are initialized to anything.
05:59
<@Derakon>
I'd much rather initialize them myself, to NULL if necessary.
06:00
< Tarinaky>
Problem is you generally only want to initialise a static variable once.
06:00
< Tarinaky>
Otherwise it's not very 'static' :p
06:00
<@Derakon>
So you do it at program start.
06:00
< celticminstrel>
True, it's better to do it yourself. But static variables are supposed to be zeroed.
06:01
< Tarinaky>
I suppose I should come clean and admit I was implementing a singleton template >.>
06:01
< Tarinaky>
Please don't hurt me q.q
06:02
<@Derakon>
Singletons aren't universally bad.
06:04 Alek [omegaboot@Nightstar-cdb0343a.emhril.sbcglobal.net] has quit [Ping timeout: 121 seconds]
06:04
< Tarinaky>
Grr. Why can't I find the code page I'm looking for :/
06:04 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has quit [[NS] Quit: Leaving]
06:07 Vornicus [vorn@ServerAdministrator.Nightstar.Net] has joined #code
06:07 mode/#code [+o Vornicus] by Reiver
06:07
< Tarinaky>
... Is it just me or isn't std::string supposed to overload operator+?
06:08 Alek [omegaboot@Nightstar-d9bf1f71.emhril.sbcglobal.net] has joined #code
06:12
<@McMartin>
Tarinaky: Not sure. Might only be +=.
06:12
<@McMartin>
As always, cplusplus.com is your friend
06:15
< Tarinaky>
It gets me -every- time >.<
06:17
< Tarinaky>
McMartin: I'm still not getting ncurses to handle unicode characters.
06:18
< celticminstrel>
Yeah, std:string overloads operator+
06:18
< Tarinaky>
I set the locale and just pretended they were normal characters - but it ended up displaying 2 characters on my terminal.
06:19
< Tarinaky>
So I tried changing to a wchar_t but, of course, that doesn't, actually, work with the function >.<
06:19
< celticminstrel>
Why would you think it doesn't overload it?
06:19
< Tarinaky>
celticminstrel: The compiler errors I get every time I try to use it?
06:19
< celticminstrel>
Example line?
06:20
< Tarinaky>
Uhh. It's somewhere in the backscroll now.
06:20
< Tarinaky>
McMartin: Nm. Got it working \o/
06:20
< celticminstrel>
The pastebin link?.
06:20
< Tarinaky>
celticminstrel: No.
06:20
< Tarinaky>
I mean my terminal's backscroll.
06:20
< celticminstrel>
Oh.
06:21
< Tarinaky>
I think it may have been something else though.
06:21
< celticminstrel>
At least one operand would have to be std::string, and the other would have to be std::string or char*; it might accept char too.
06:22
< Tarinaky>
I -think- it was because I was accidentally passing a wchar_t to it.
06:22
< Tarinaky>
Which it didn't like for obvious reasons.
06:22
< celticminstrel>
Well, okay. I hope you get it working.
06:22 * celticminstrel falls asleep.
06:22
< celticminstrel>
(Ah, yes. Narrow and wide STL objects don't work together. They really should, in my opinion...)
06:23 celticminstrel [celticminstre@Nightstar-f8b608eb.cable.rogers.com] has quit [[NS] Quit: *hums* Can't stay now!]
06:50 Derakon is now known as Derakon[AFK]
07:07 You're now known as TheWatcher
07:24 AnnoDomini [annodomini@Nightstar-a18fcd04.adsl.tpnet.pl] has joined #code
07:24 mode/#code [+o AnnoDomini] by Reiver
07:38
< Tarinaky>
Morning AD!
07:39
<@TheWatcher>
How go you two's roguelikes, idly?
07:40
< Tarinaky>
Well, since deciding to start again I then had two weeks where I wasn't able to work on it.
07:40
< Tarinaky>
Busy weekends :/
07:40
< Tarinaky>
I managed to put some time in this morning though.
07:40
< Tarinaky>
http://github.com/Tarinaky/ironsoulrl
07:49
<@AnnoDomini>
EXAM SEASON.
07:49 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has joined #code
07:51
< Tarinaky>
Heh.
08:06 * TheWatcher eyes AD, for some reason his brain assigned that statement the voice of the Mad Hatter...
08:14 You're now known as TheWatcher[afk]
08:18
< Tarinaky>
I have a friend who needs help trying to grasp the programming labs :/
08:18
< Tarinaky>
Any suggestions on anything I can throw at him so he stops bugging me?
08:18
< Tarinaky>
I have enough on my plate with my own work. Nm anyone elses :x
09:27 Attilla [Attilla@FBC920.58502B.4BF0F8.FCE0D3] has joined #code
09:28 mode/#code [+o Attilla] by Reiver
10:05
<@TheWatcher[afk]>
Tarinaky: Unix Network Programming: Networking APIs: Sockets and XTI; volume 1.
10:06
<@TheWatcher[afk]>
It probably won't help him, but the concussion should keep him out of your hair for a while.
10:06 You're now known as TheWatcher
10:06
< Tarinaky>
When I said 'stop bugging me' I didn't mean giving him...
10:06
< Tarinaky>
Yeah, you beat me to it >.>
10:06
< Tarinaky>
Besides, for that I have my C++ Reference book.
10:07
< Tarinaky>
But I don't want to get blood on it - I practically worship that book >.>
10:08
<@TheWatcher>
But but
10:08
<@TheWatcher>
Think; if you hit him hard enough, you'd be able to rebind the book in genuine human skin!
10:08
<@TheWatcher>
>.>
10:09
< Tarinaky>
But then how will I tell it from my lab-book?
10:09 Rhamphoryncus [rhamph@Nightstar-8931f88f.abhsia.telus.net] has quit [Client exited]
10:09
<@TheWatcher>
hm. That's a point,
10:11
< Tarinaky>
By Cantor, the black dust of a thousand points. By Julia - the imprisoned square. Ia Ia Fractal fhtagn!
10:11
< Tarinaky>
*black dust of the machine with a thousand points
10:12
< Tarinaky>
Which would be funny except trying to read the lecturer's completely commentless programs whose symbol names consist of 2 characters really is like trying to read the King in Yellow :/
10:13
< Tarinaky>
And then he picks a fight with me because I don't declare my variables at the start of functions...
10:13
< Tarinaky>
Physicists really are the worst people I know :/
10:13
<@TheWatcher>
Hah
10:13
<@TheWatcher>
you should read code written by biologists.
10:14 * TheWatcher shudders
10:14
< Tarinaky>
I'd really rather not.
10:14
< Tarinaky>
Molecular biology/chemistry is just applied quantum physics.
10:14 * Tarinaky ducks.
10:16
<@TheWatcher>
"Physis is the only real science. The rest are stamp collecting" ;)
10:16
<@TheWatcher>
*physics
10:18
<@TheWatcher>
(if you ever want to look at cthulhuian code, download Bodington and look at that. Just be sure to draw a protective pentagram around the computer first)
10:18
< Tarinaky>
Ooo. Scary/interesting thought. Quantum Computers would totally revolutionise molecular biology and pharmecuticals
10:20
< Tarinaky>
Anyway. I need to get working. I wanna get some programming done.
10:21
< Tarinaky>
"Enough yappin'."
10:48
< Tarinaky>
If I have an abstract class that overloads the assignment operator - what do I do for the assignment operator of the derived classes?
10:49
< Tarinaky>
I'll note the assignment operator of the base class is -not- virtual.
10:49
< Tarinaky>
Will it be called automatically to handle the base-class members?
10:51
<@Vornicus>
I don't think you can ever expect a function to call its parent's equivalent.
10:52
< Tarinaky>
I'm not really sure what I should do then :/
10:52
< Tarinaky>
I need to overload the assignment operator because I have a pointer.
10:52
< Tarinaky>
Which means I need a copy-constructor and an operator=.
11:04 Serah [Z@3A600C.A966FF.5BF32D.8E7ABA] has joined #code
11:40 Serah [Z@3A600C.A966FF.5BF32D.8E7ABA] has quit [[NS] Quit: Rebooting.]
11:41 Serah [Z@3A600C.A966FF.5BF32D.8E7ABA] has joined #code
13:34 AbuDhabi [annodomini@Nightstar-8b8d9687.adsl.tpnet.pl] has joined #code
13:36 AnnoDomini [annodomini@Nightstar-a18fcd04.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
13:39 gnolam [lenin@Nightstar-38637aa0.priv.bahnhof.se] has joined #code
14:04 Tarinaky [Tarinaky@Nightstar-f92d66ca.adsl.virginmedia.net] has quit [Operation timed out]
14:05 Tarinaky [Tarinaky@Nightstar-f92d66ca.adsl.virginmedia.net] has joined #code
14:05 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has joined #code
14:16 * gnolam tsks at Creative.
14:19
< gnolam>
They're doing some quite obvious stealth marketing on a forum I frequent.
14:22
< gnolam>
Note to sleazy marketers: if you're going to astroturf, at least make some non-product-related posts /before/ you clumsily start trying to generate buzz.
15:03 You're now known as TheWatcher[afk]
15:43 Thaqui [Thaqui@27B34E.D54D49.F53FA1.6A113C] has quit [Client closed the connection]
16:30 You're now known as TheWatcher
16:49 Serah [Z@3A600C.A966FF.5BF32D.8E7ABA] has quit [Ping timeout: 121 seconds]
18:11 Netsplit *.net <-> *.split quits: Alek, AbuDhabi, @Vornicus, gnolam, @Kazriko, crem, Reiver
--- Log closed Tue Feb 09 18:15:03 2010
--- Log opened Tue Feb 09 18:28:02 2010
18:28 TheWatcher [chris@Nightstar-b4529b0c.zen.co.uk] has joined #code
18:28 Irssi: #code: Total of 13 nicks [3 ops, 0 halfops, 0 voices, 10 normal]
18:28 mode/#code [+o TheWatcher] by Reiver
18:28 Irssi: Join to #code was synced in 44 secs
18:35 jerith [jerith@Nightstar-bf52129d.slipgate.za.net] has joined #code
18:35 SmithKurosaki [Smith@Nightstar-a68aafef.dsl.teksavvy.com] has joined #code
18:35 Namegduf [namegduf@Nightstar-7ec84b32.bath.ac.uk] has joined #code
18:35 ToxicFrog [ToxicFrog@Nightstar-a68aafef.dsl.teksavvy.com] has joined #code
18:35 EvilDarkLord [jjlehto3@Nightstar-f1ccbb45.hut.fi] has joined #code
18:35 McMartin [mcmartin@Nightstar-592271c1.pltn13.sbcglobal.net] has joined #code
18:35 ServerMode/#code [+oo ToxicFrog McMartin] by *.Nightstar.Net
18:35 mode/#code [+o jerith] by Reiver
18:39 Serah [Z@26ECB6.A4B64C.298B52.D80DA0] has joined #code
18:47 AnnoDomini [annodomini@Nightstar-8b8d9687.adsl.tpnet.pl] has joined #code
18:47 mode/#code [+o AnnoDomini] by Reiver
18:48 AbuDhabi [annodomini@Nightstar-8b8d9687.adsl.tpnet.pl] has quit [Ping timeout: 121 seconds]
19:11 celticminstrel [celticminstre@Nightstar-f8b608eb.cable.rogers.com] has joined #code
20:11 Syloqs_AFH [Syloq@NetworkAdministrator.Nightstar.Net] has joined #code
20:12 Syloqs_AFH is now known as Syloqs-AFH
--- Log closed Tue Feb 09 20:44:11 2010
--- Log opened Tue Feb 09 21:04:13 2010
21:04 TheWatcher [chris@Nightstar-b4529b0c.zen.co.uk] has joined #code
21:04 Irssi: #code: Total of 19 nicks [6 ops, 0 halfops, 0 voices, 13 normal]
21:04 mode/#code [+o TheWatcher] by Reiver
21:05 Irssi: Join to #code was synced in 53 secs
21:41 Zed [Zed@Nightstar-d0088b95.or.comcast.net] has joined #code
22:00 Serah [Z@26ECB6.A4B64C.298B52.D80DA0] has quit [Client closed the connection]
22:00 Serah [Z@26ECB6.A4B64C.298B52.D80DA0] has joined #code
22:31 Derakon[work] [Derakon@Nightstar-1ffd02e6.ucsf.edu] has joined #code
22:31
< Derakon[work]>
G'day, folks.
22:31
< Derakon[work]>
Any of you know of a good tool for fixing whitespace inconsistencies in C++ code?
22:31
< Derakon[work]>
Because I'm having to read some of Sebastian's ouvres in that area now, and lemme tell you, it's painful.
22:32
< Derakon[work]>
We're talking a mix of tabs and two-, three-, and four-space indenting. Sometimes on the same line.
22:34
<@AnnoDomini>
I take it it's a lot of code - too much to fix by hand.
22:34
< Derakon[work]>
% wc -l *cpp *hh | tail -1
22:35
< Derakon[work]>
4248 total
22:35
< Namegduf>
Regex?
22:35
< Derakon[work]>
I'd really rather not try to do this by hand.
22:35
< Derakon[work]>
Either manually or by trying to write my own prettyprinter.
22:36
< Derakon[work]>
Hmm... the "indent" program might do what I want.
22:37
< Derakon[work]>
Hmph. But its support for C++ is "experimental".
22:37
<@McMartin>
Is that the stock prettyprinter?
22:38
< Derakon[work]>
I tried running it with no arguments except for an input and output file, and got 12 errors and 1 warning.
22:38
< Derakon[work]>
McM: I guess?
22:38
<@McMartin>
Looks like
22:38 * McMartin pokes at the Fedora repos.
22:39
< Derakon[work]>
Good gravy it has a lot of options.
22:39
<@McMartin>
And it's still not enough to capture all indentation arguments!
22:41
<@TheWatcher>
script emacs to load, indent, and save the files? ¬¬
22:41
<@McMartin>
Step 1: learn LISP
22:41
<@McMartin>
Step 2: learn the Emacs equivalent of all the necessary options, all of which indent has
22:41
<@McMartin>
Step 3: Script emacs instead of shell
22:42
<@McMartin>
Overall, even as an emacs partisan, I can't recommend this
22:45 * Derakon[work] does a cursory check with the default arguments, discovers that indent has uncommented code that was originally commented out, causing the creation of an "else if" with no preceding "if".
22:46
<@AnnoDomini>
How is that possible?
22:48
< Derakon[work]>
I don't know.
22:55
< Derakon[work]>
Hm. indent doesn't seem too happy about all these curly-free if statements.
22:55
< Derakon[work]>
It'd be nice if those were recognized and curlies inserted.
23:05
< Derakon[work]>
I see it also didn't do anything about this:
23:05
< Derakon[work]>
double fac = histogram_displayed_max > 1
23:05
< Derakon[work]>
? (double (h - 20) / (m_log ? log(histogram_displayed_max + 1.0) : histogram_displayed_max))
23:12 * Derakon[work] tries to figure out what the _T function is, does a google search for "wx _T", eyes the first result.
23:13
< Alek>
thermowood-user-guide-in-french.pdf?
23:13
< Derakon[work]>
Ah ha. It's a wx macro that converts the passed-in string literal to UTF-8 as appropriate.
23:16
< Tarinaky>
wx is a pain in the arse imo.
23:16
< Derakon[work]>
I'm kinda stuck with it.
23:16
< Derakon[work]>
I don't have anywhere near the resources needed to port to a different system.
23:17
< Tarinaky>
Most GUI libs are a pita sadly :/
23:18
< Derakon[work]>
I'd be reasonably happy with something that basically worked by HTML with embedded OpenGL.
23:19
<@TheWatcher>
use glade then~
23:20
<@TheWatcher>
(yes, I am being facetious)
23:24
< Derakon[work]>
Different subject: we have a rotatable display. When it's oriented normally, everything works fine. When it's rotated 90?, the text in one OpenGL surface flickers (while the rest of it does not). Any ideas what could be causing that?
23:25 MyCatVerbs [mycatverbs@Nightstar-58acb782.cable.virginmedia.com] has joined #code
23:25 mode/#code [+o MyCatVerbs] by Reiver
23:26
< Derakon[work]>
...oh, wait, I think I have an idea about that. Nemmind.
23:38
< Derakon[work]>
Nope, that just made it so it flickers all the time, instead of just when the display is rotated.
23:40
< Derakon[work]>
Anyone want to take a look? http://pastebin.starforge.co.uk/125
23:40
< Derakon[work]>
The change I tried was moving lines 70-72 to the end of the function.
23:40
< Derakon[work]>
The text is drawn at lines 85-89.
23:46
<@TheWatcher>
wx doesn't have its own function to swap the buffers, does it?
23:46
< Derakon[work]>
I have basically no idea how WX and OpenGL interact.
23:47
< Derakon[work]>
Right now I'm investigating trying to get the text drawing to be done in OpenGL too, since everything else using OpenGL seems to work fine.
23:48 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has quit [Ping timeout: 121 seconds]
23:48
<@TheWatcher>
yeah, about that
23:48
< Derakon[work]>
Apparently drawing text with OpenGL is nontrivial.
23:49
<@TheWatcher>
quite
23:49
< Derakon[work]>
Fuck me.
23:49
<@TheWatcher>
I'd rather not; Myst would object.
23:49
< Derakon[work]>
Mm, come to think, I would too.
23:52
<@TheWatcher>
nehe has some stuff on it - lesson 17 may be the 'simplest', but it is pretty much restricted to proportional fonts. lesson 43 goes over using freetype instead, but that's pretty nasty really
23:52 crem [moo@Nightstar-8ca3eea7.adsl.mgts.by] has joined #code
23:53 * Derakon[work] eyes http://www.opengl.org/resources/features/fontsurvey/
23:54
< Derakon[work]>
Apparently GLUT has some functions I could use, and I'm already including something called "glu32.lib" which I think is GLUT.
23:54
< Derakon[work]>
Mind, 'grep -i glut *' in the src directory turns up nothing.
23:55
<@TheWatcher>
glu != glut
23:55
< Derakon[work]>
Ah. OpenGL Utility Library.
23:55
< Derakon[work]>
Nemmind then.
23:57
< Derakon[work]>
Looks like most of the libraries for this require GLUT anyway, though.
--- Log closed Wed Feb 10 00:00:41 2010
code logs -> 2010 -> Tue, 09 Feb 2010< code.20100208.log - code.20100210.log >