You can subscribe to this list here.
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(115) |
Aug
(120) |
Sep
(137) |
Oct
(170) |
Nov
(461) |
Dec
(263) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(120) |
Feb
(74) |
Mar
(35) |
Apr
(74) |
May
(245) |
Jun
(356) |
Jul
(240) |
Aug
(115) |
Sep
(78) |
Oct
(225) |
Nov
(98) |
Dec
(271) |
2009 |
Jan
(132) |
Feb
(84) |
Mar
(74) |
Apr
(56) |
May
(90) |
Jun
(79) |
Jul
(83) |
Aug
(296) |
Sep
(214) |
Oct
(76) |
Nov
(82) |
Dec
(66) |
2010 |
Jan
(46) |
Feb
(58) |
Mar
(51) |
Apr
(77) |
May
(58) |
Jun
(126) |
Jul
(128) |
Aug
(64) |
Sep
(50) |
Oct
(44) |
Nov
(48) |
Dec
(54) |
2011 |
Jan
(68) |
Feb
(52) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
2018 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
1
(3) |
2
(2) |
3
(6) |
4
(4) |
5
(1) |
6
|
7
|
8
|
9
|
10
|
11
(1) |
12
(1) |
13
(1) |
14
(4) |
15
|
16
(8) |
17
(7) |
18
(5) |
19
|
20
|
21
(2) |
22
|
23
(2) |
24
|
25
(2) |
26
(6) |
27
(3) |
28
(2) |
29
(2) |
30
(2) |
31
|
|
|
|
|
Revision: 8625 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8625&view=rev Author: mdehoon Date: 2010年08月11日 03:23:59 +0000 (2010年8月11日) Log Message: ----------- The MacOS module will disappear in Python 3. Implement the WMAvailable() check in the C code in src/_macosx.m, so we won't rely on the MacOS module. Modified Paths: -------------- trunk/matplotlib/lib/matplotlib/backends/backend_macosx.py trunk/matplotlib/src/_macosx.m Modified: trunk/matplotlib/lib/matplotlib/backends/backend_macosx.py =================================================================== --- trunk/matplotlib/lib/matplotlib/backends/backend_macosx.py 2010年08月05日 17:04:14 UTC (rev 8624) +++ trunk/matplotlib/lib/matplotlib/backends/backend_macosx.py 2010年08月11日 03:23:59 UTC (rev 8625) @@ -2,7 +2,6 @@ import os import numpy -import MacOS from matplotlib._pylab_helpers import Gcf from matplotlib.backend_bases import RendererBase, GraphicsContextBase,\ @@ -229,7 +228,7 @@ """ Create a new figure manager instance """ - if not MacOS.WMAvailable(): + if not _macosx.get_main_display_id(): import warnings warnings.warn("Python is not installed as a framework. The MacOSX backend may not work correctly if Python is not installed as a framework. Please see the Python documentation for more information on installing Python as a framework on Mac OS X") FigureClass = kwargs.pop('FigureClass', Figure) Modified: trunk/matplotlib/src/_macosx.m =================================================================== --- trunk/matplotlib/src/_macosx.m 2010年08月05日 17:04:14 UTC (rev 8624) +++ trunk/matplotlib/src/_macosx.m 2010年08月11日 03:23:59 UTC (rev 8625) @@ -4399,16 +4399,6 @@ return Py_None; } -static char show__doc__[] = "Show all the figures and enter the main loop.\nThis function does not return until all Matplotlib windows are closed,\nand is normally not needed in interactive sessions."; - -static PyObject* -show(PyObject* self) -{ - if(nwin > 0) [NSApp run]; - Py_INCREF(Py_None); - return Py_None; -} - @implementation Window - (Window*)initWithContentRect:(NSRect)rect styleMask:(unsigned int)mask backing:(NSBackingStoreType)bufferingType defer:(BOOL)deferCreation withManager: (PyObject*)theManager { @@ -5139,11 +5129,31 @@ } @end + +static PyObject* +show(PyObject* self) +{ + if(nwin > 0) [NSApp run]; + Py_INCREF(Py_None); + return Py_None; +} + +static PyObject* +get_main_display_id(PyObject* self) +{ + CGDirectDisplayID display = CGMainDisplayID(); + if (display == 0) { + PyErr_SetString(PyExc_RuntimeError, "Failed to obtain the display ID of the main display"); + return NULL; + } + return PyInt_FromLong(display); +} + static struct PyMethodDef methods[] = { {"show", (PyCFunction)show, METH_NOARGS, - show__doc__ + "Show all the figures and enter the main loop.\nThis function does not return until all Matplotlib windows are closed,\nand is normally not needed in interactive sessions." }, {"choose_save_file", (PyCFunction)choose_save_file, @@ -5155,11 +5165,17 @@ METH_VARARGS, "Sets the active cursor." }, + {"get_main_display_id", + (PyCFunction)get_main_display_id, + METH_NOARGS, + "Returns the display ID of the main display. This function fails if Python is not built as a framework." + }, {NULL, NULL, 0, NULL}/* sentinel */ }; void init_macosx(void) { PyObject *m; + import_array(); if (PyType_Ready(&GraphicsContextType) < 0) return; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.