Popular recipes tagged "meta:requires=tkinter.simpledialog"http://code.activestate.com/recipes/tags/meta:requires=tkinter.simpledialog/2014-09-05T15:02:11-07:00ActiveState Code RecipesGame of Life - Python 3.4 & tkinter (Python)
2014-09-05T15:02:11-07:00Peter Mhttp://code.activestate.com/recipes/users/4190729/http://code.activestate.com/recipes/578928-game-of-life-python-34-tkinter/
<p style="color: grey">
Python
recipe 578928
by <a href="/recipes/users/4190729/">Peter M</a>
(<a href="/recipes/tags/python3/">python3</a>, <a href="/recipes/tags/tkinter/">tkinter</a>).
</p>
<p>I took this well-know game to design my own solution, and make a GUI for it.</p>
<p>To run the program, you will need to create a txt file with rows of dots, so like this:</p>
<p>......
......
......
......</p>
<p>and name it empty_board.gol
(I have tested this program withwith 55x55)</p>
<p>It is functional and not object oriented.</p>
<p>My game of life algorithm is probably not the best one around (suggestions welcome), but I think this program is a nice demo of with tkinter can do and how easy it is to program GUI's with tkinter.</p>
<p>It has been written and tested in python 3.4 but I guess any version 3 should work, and probably only minor changes are needed to make it work in 2.6 or 2.7 (e.g. change tkinter to Tkinter).</p>
Text Editor in Python 3.3 (Python)
2013-06-19T15:58:17-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/578569-text-editor-in-python-33/
<p style="color: grey">
Python
recipe 578569
by <a href="/recipes/users/2608421/">Stephen Chappell</a>
(<a href="/recipes/tags/editor/">editor</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/text/">text</a>, <a href="/recipes/tags/text_processing/">text_processing</a>).
</p>
<p>This is a simple text editor written in Python using <code>tkinter</code> for graphics.</p>
<p>Check out Captain DeadBones' <a href="http://thelivingpearl.com/">Chronicles</a> blog.</p>
MineSweep (Python)
2010-09-16T14:45:36-07:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577365-minesweep/
<p style="color: grey">
Python
recipe 577365
by <a href="/recipes/users/2608421/">Stephen Chappell</a>
(<a href="/recipes/tags/game/">game</a>, <a href="/recipes/tags/minesweep/">minesweep</a>, <a href="/recipes/tags/python/">python</a>).
Revision 2.
</p>
<p>A friend was wondering how to implement MineSweep and decided to try making the game in Excel. Unfortunately, the game was not quite as interactive as he wanted; and he is unable to get around certain limitations at the moment since he is still new to programming. To show off the power of Python and demonstrate how easy it can be to develop a simple demonstration program in the language, the following program (and its iterations) were put together between the hours of 1 and 6 in the morning. It could certainly be much better in its implementation, but any serious work were to be put into MineSweep, starting over from scratch would be the best choice (especially with interface design).</p>