Download Current version: 2.19.2 Changelog Get Pygments from the Python Package Index, or install it with: pip install Pygments Questions? Suggestions? Clone at GitHub. You can also open an issue at the tracker. A project Welcome!¶ This is the home of Pygments. It is a generic syntax highlighter suitable for use in code hosting, forums, wikis or other applications that need to prettify source code
In this post, I’ll detail how to catch specific key presses and why this can be useful. This is another in my series of “requested” tutorials. There really isn’t much to catching key presses, but it can be a little confusing when one widget behaves slightly differently from another. The really complicated stuff comes in when you need to capture the EVT_CHAR. First I’ll cover the key events, wx.EVT
今回はwxGlade及びwxPythonを使ったリハビリ作の第一弾です。 既存のpingコマンドにGUIのインタフェースを付けてしまおうです。 環境設定は前回までで完了しているということで進めます。 参考(ま、お好みでどうぞ) Ubuntu 10.04 でwxPythonとwxGladeプレビュー編 Eclipse 3.6 へのPydevインストールとwxPythonのコード補完有効化 順を追って説明して行きましょう まず何よりも、どんなアプリを作りたいのか見た目やプロトタイプを作りましょう。 実際のところ、どうやってこの工程を進めるかというのは慣れや感性によると思います。wxGladeで作りやすいかどうかということもあります。慣れてくると何となくサクッと決められるようになるはずです。 今回はとりあえず以下のようなものを作ることにいたしましょう。 実際に作り始める前に、プロジェクトを作成し
GUIアプリケーションの上部に表示され、終了や保存などの様々なアクションの起点ともなるMenuBarの紹介です。本項ではMenuおよびMenuItemについても扱います。 基本的な使い方 Appendを使用してMenuを追加し、FrameのSetMenuBarにてメニューバーをセットします。 import wx application = wx.App() frame = wx.Frame(None, wx.ID_ANY, 'テストフレーム', size=(300, 200)) panel = wx.Panel(frame, wx.ID_ANY) panel.SetBackgroundColour('#AFAFAF') menu_file = wx.Menu() menu_edit = wx.Menu() menu_bar = wx.MenuBar() menu_bar.Append(me
last modified January 10, 2023 This is wxPython tutorial. In this tutorial, you will learn the basics of GUI programming in wxPython. The tutorial is suitable for beginners and intermediate programmers. The tutorial covers wxPython Phoenix version 4.0.1. The sources of the examples are available at the wxPython-examples repository. Table of contents wxPython is a cross platform toolkit for creatin
複数プロジェクトを抱えるチームでのデプロイ自動化 1つのチームで,10以上のプロジェクト,コードベースを抱える場合にどのようにデプロイの自動化を進めたか,工夫したこと,考慮したことなどをまとめておく. デプロイツールには,Python製のfabricを採用しているが,他のツールでも同様のことはできそう.なお,fabricの基本的な使い方などは既にインターネット上に良い記事がたくさんあるので書かない(最後の参考の項を見てください). fabricの選択 シェルスクリプトとCapistranoを考慮した. まず,シェルスクリプトは人によって書き方が違うため,統一が難しくメンテナンスコストも高い.また共通化も難しい. 次に,Capistranoは,裏でやってくれることが多く,学習コストも高い.プロジェクトによってはかなり特殊な環境へのデプロイも抱えているため,Capistranoの前提から外れる
1月に「Pythonを始めるなら、1ファイルの軽量Webフレームワーク「Bottle」がおすすめ」というのを書いたところ、なかなか反響が大きかった。そこで今回は、私がいくらか使ったことがあるPythonのWebフレームワーク6種について、かんたんに紹介するというのをやってみたい。コメントは、私のごく主観的な印象に基づいている。 Bottle(ボトル) http://bottlepy.org/ 「bottle.py」という1ファイルだけでできている。環境構築が不要なので、Python入門に最適。1ファイルに全部入っているので、組み込むのも容易だし、依存リスクもないので、実用にもいいと思う。これだけシンプルなのは、生存戦略としても強い。 CherryPy(チェリーパイ) http://cherrypy.org/ Bottleより大きいが、外部依存がないので、これも環境構築不要で、Python入
PlotDevice A Python-based graphics language for designers, developers, and tinkerers A Scriptable Graphics Factory PlotDevice is a Macintosh application that lets you write Python scripts to generate 2D graphics using simple drawing commands. Under the hood, your code drives the system's Quartz imaging engine, giving your scripts the same graphical power as a full-fledged Cocoa app. Your code can
I want to install PIL on Mavericks using pip but get this error. _imagingft.c:73:10: fatal error: 'freetype/fterrors.h' file not found #include <freetype/fterrors.h> ^ 1 error generated. error: command 'cc' failed with exit status 1 My Command Line Tools are installed and up to date and every hint I found didn't help. How can I get this to compile? EDIT: I just checked, freetype is also already in
Kivy has been built to be easy to use, cross-platform and fast. With a single codebase, you will be able to deploy apps on Windows, Linux, macOS, iOS and Android. Business Friendly Kivy is released under the MIT License, is 100% free to use, and is professionally developed, backed and maintained. Companies and individuals are using Kivy for their projects every day.
Welcome to Read the Docs¶ This is an autogenerated index file. Please create a /home/docs/checkouts/readthedocs.org/user_builds/pythonjs/checkouts/latest/doc/index.rst or /home/docs/checkouts/readthedocs.org/user_builds/pythonjs/checkouts/latest/doc/README.rst file with your own content. If you want to use another markup, choose a different builder in your settings.
I was born and raised in Thousand Oaks, CA . I have watched as my State/Country has tumbled into chaos and despotism. It has gotten so bad I cannot foresee a future I would want to raise children in. I was fortunate enough to grow up in a beautiful City by loving parents, I want the same for future generations. Too long have I sat on the sidelines expecting my “representatives” to take correct and
Windows7上に作ったシリアル通信のテスト環境で、Pythonによるシリアル通信を試してみた。今回使ったはPySerial2.5とPython2.6だ。 PythonアプリケーションとTeraTermとの間で読み書きできることを確認できた。 以下は、COM20とCOM21を仮想接続した状態で、TeraTermでCOM20に接続し、PythonアプリケーションでCOM21に接続する場合だ。 (1)COM21に接続して"hello"を入力してポートを閉じる >>> import serial >>> ser = serial.Serial(20) >>> print ser.portstr >>> ser.write("hello") >>> ser.close() するとTeraTermに"hello"が表示される。 (2)COM21に接続してTeraTermからの入力を待つ >>> s
デスクトップ通知とは、デスクトップで全てのアプリケーションより上のレイヤにバルーンあるいはポップアップの形式でメッセージを表示するものを指す。 結果の出力に時間のかかるプログラムを端末で動かしている場合など、プログラムを動かしている端末から目を離したい場合が時々ある。しかし、プログラムがエラーにより落ちたり、あるいは正常に終了した場合に、端末から目を離していてはすぐに対応することが出来ない。 そこで、プログラムからデスクトップ通知を用いることで、全てのアプリケーションより上のレイヤに任意のメッセージを表示することが出来るので、プログラムの挙動に対しすぐに対応することが出来る。 Mac環境のデスクトップ通知: Growl Macでデスクトップ通知と言えばGrowlがある。 AppleScriptによるGrowlによるデスクトップ通知を出すプログラムは以下のようになる。 tell applic
Last year, we covered some tips and tricks for the Grid control.In this article, we will go over a few tips and tricks for the wx.ListCtrl widget when it’s in “report” mode. Take a look at the tips below: How to create a simple ListCtrl How to sort the rows of a ListCtrl How to make the ListCtrl cells editable in place Associating objects with ListCtrl rows Alternate the row colors of a ListCtrl H
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く