Sample code usable Tkinter listbox723 (3/1/2010 12:30:12 AM) comp.lang.python In case Someone Else(TM) may need this. This code is just how it currently looks, what I needed for my code, so it's not a full-fledged or even tested class. But it works. import tkinter as t import tkint... Alf
A silly macro technique552 (2/23/2010 11:11:10 AM) comp.lang.c++ Replace "debugger api" with "whatever" in this #define USE_DEBUGGER_API // Or not extern void useDebuggerApi(); #define CALL_IF_EXPANDED( doIt, f ) \ struct S_##f { ... Alf
MSVC sillywarnings -- more?1136 (2/23/2010 10:02:36 AM) comp.lang.c++ I just added MSVC sillywarnings to this list as I encountered them. Are there more that should be added? Note: "unreferenced" warnings are handled by other explicit mechanism. // Copyright (c) Alf P. Stein... Alf
Easter Eggs421 (2/9/2010 11:40:50 PM) comp.lang.python I know 3 Python Easter Eggs, from __future__ import braces import this help( "antigravity" ) Are there more? Cheers, - Alf ... Alf
TABS in the CPython C source code1727 (2/6/2010 8:31:52 PM) comp.lang.python Just trying to delve into the CPython source code. Pleasant surprise: while e.g. the gcc compiler is written in K&R C (1975 style C), CPython seems to be written in almost modern C (1989 and on). But, hey, T... Alf
A simple-to-use sound file writer4835 (1/14/2010 5:09:33 AM) comp.lang.python Just as a contribution, since someone hinted that I haven't really contributed much to the Python community. The [simple_sound] code will probably go into my ch 3 at , but sans sine wave generation since I h... Alf
Those two controversial 2nd & 3rd paragraphs of my ch 11328 (1/13/2010 2:41:25 PM) comp.lang.python Referring to Due to especially Steven D'Aprano's comments I've replaced "hopeless" with "very hard" in paragraph 1 of section 1.1 -- I know he'll disagree with that also but I think any more downplaying o... Alf
Does turtle graphics have the wrong associations?1531 (11/12/2009 6:21:01 AM) comp.programming One reaction to has been that turtle graphics may be off-putting to some readers because it is associated with children's learning. What do you think? Cheers, - Alf ... Alf
[ANN] pyjamas 0.7 released710 (4/25/2010 1:49:58 PM) comp.lang.python pyjamas - the stand-alone python-to-javascript compiler, and separate
GUI Widget Toolkit, has its 0.7 release, today. this has been much
delayed, in order to allow the community plenty of time between the
0... Luke
iostream >> string, but fixed length string - how?1653 (4/30/2010 12:38:43 PM) comp.lang.c++ Hi all, I'd like to read a fixed number of bytes from a binary file into a std::string. I have been doing this sort of thing: char foo[123]; stream.read(foo, 123); std::string bar(foo); However I woul... a.nielsen382(6)
The joy (?) of C++98 argument forwarding624 (5/3/2010 9:48:51 AM) comp.lang.c++ Consider ...
// Copyright (c) Alf P. Steinbach, 2010.
#include "_config.h"
#include
#include
namespace {
using namespace progrock;
cppx::Size count = 0;
class Fo... Alf
Throwing error is potentially buggy2539 (6/10/2010 4:58:36 AM) comp.lang.c++ Note: This thread is from comp.lang.c++.moderated, moved here because I failed twice to reply. Please refer the original thread for context. On 6=E6=9C=888=E6=97=A5, =E4=B8=8B=E5=8D=885=E6... wij(60)
Tkinter Toplevel sizing issue (using a grid)224 (6/11/2010 11:40:06 PM) comp.lang.python Hello all, Hi this i my first post here. I would like to create a tkinter toplevel window with a custom resize action based on a grid. From the Tk docs it say you can do this but for the life of me i cannot fi... pywin32(9)
Linked list question1035 (6/13/2010 12:18:45 AM) comp.programming Let's say I have function called delete() that takes a string 's' as its argument. This functions sole purpose is to delete a node from a singly linked list. The pseudo code would be like the following.... voi... cdalten(976)
variable placement in structures12148 (6/14/2010 10:56:48 AM) comp.lang.c++ Hi All .. I am facing a rather strange issue.
I have a struct A which is part of struct B as follows:
struct A{
int a;
int b;
....
}
struct B{
struct A a;
int x;
int y;
....
}
so whenever i a... omnia
A question about TC++PL1990 (6/15/2010 4:11:49 PM) comp.lang.c++
Dear All,
I'm reading appendix C.13.8.3 in TC++PL special ed. and it says:
"
The definition of "instantiation point" implies that a template
parameter can never be bound to a local name or a class mem... ekschencn(3)
Overriding "__setattr__" of a module - possible?22117 (6/16/2010 2:43:29 AM) comp.lang.python Is it possible to override "__setattr__" of a module? I
want to capture changes to global variables for debug purposes.
None of the following seem to have any effect.
modu.__setattr__ = myfn
... nagle(1022)