Welcome![Sign In][Sign Up]
Location:
Search - python embed m

Search list

[OtherPyEmbedMFC_src

Description: Python语言嵌入到MFC的开发中,通过这个例子可以利用两种语言的优势开发程序-Many of you might have seen the numeric input fields in most commercial CAD and scientific applications that facilitate the user to write mathematical expressions. This is to allow the user to use the edit box or the spinner box as a calculator on the fly. I was very much fascinated with this functionality and always wanted to easily have it in my applications. Writing a parser was a long job. When I just started learning Python, I came to know that it was a beautiful calculator by itself. You just need to type the expression on the command line and return-- you get the answer for any math function the C programmer is familiar with. After a long search on the net and the Python API doc, I finally came to know how to simply send a string to the interpreter and retrieve the results. I leveraged this ability of the Python API to embed it into a dialog box.
Platform: | Size: 25600 | Author: liulei | Hits:

CodeBus www.codebus.net