Macro FCInfo Alternate Linux

From FreeCAD Documentation
Jump to: navigation, search
Other languages:
čeština • ‎Deutsch • ‎English • ‎français • ‎italiano

FCInfo.png Macro FCInfo Alternate Linux

Description
Gives a series of information on the form. (only for PyQt4)

Macro version : 1.12
Date last modification : 2014-03-05
Author
Mario52
Download
None
Links
Macro Version
1.12
Date last modification
2014-03-05
FreeCAD Version(s)
None
Default shortcut
None
See also
Macro_FCInfo


Description

Gives a series of informations about the selected shape and can display a conversion of length, inclination (degrees, radians, grades, pourcent) shape, surface, volume and the weight of the form in the density selected in different units of quantities international and Anglo-Saxon (only for PyQt4).

Temporary code for external macro link. Do not use this code. This code is used exclusively by Addon_Installer.


##This code is copied instead of the original macro code

##to guide the user to the offline download page

##Use it if the code of the macro is larger than 64 KB and cannot be included in the wiki

##or if the RAW code url is extra wiki location

import PySide

from PySide import QtGui ,QtCore

diag = QtGui.QMessageBox(QtGui.QMessageBox.Information,u"Information",
    "This macro must by downloaded with this link" + "\n"
    " " + "\n"
    "https://gist.githubusercontent.com/mario52a/6c6b6131b0c14d800033/raw/ffa3d6857abb0ea207cee1ae13c1cb78edadbcf5/FCInfo_fr_Ver_1-12_No_Docked_Ubuntu.FCMacro" + "\n"
    " " + "\n"
    "Quit this window for access in the download page" )

diag.setWindowFlags(PySide.QtCore.Qt.WindowStaysOnTopHint)

diag.setWindowModality(QtCore.Qt.ApplicationModal)

diag.exec_()

import webbrowser 

webbrowser.open("https://gist.githubusercontent.com/mario52a/6c6b6131b0c14d800033/raw/ffa3d6857abb0ea207cee1ae13c1cb78edadbcf5/FCInfo_fr_Ver_1-12_No_Docked_Ubuntu.FCMacro")
<class="rawcodeurl"><a href="https://gist.githubusercontent.com/mario52a/6c6b6131b0c14d800033/raw/ffa3d6857abb0ea207cee1ae13c1cb78edadbcf5/FCInfo_fr_Ver_1-12_No_Docked_Ubuntu.FCMacro">raw code</a>


The server does not accept for the moment of the more pages of 64 KB and it was impossible to update and restore this page to me.

Script

Download the file here :

FCInfo_en_Ver_1-12_No_Docked_Ubuntu.FCMacro.zip

Or on the forum

The difference between the regular version and the version "Ubuntu" in another type of encoding of the characters above + 128 with the procedure
PS: this version is derived from the original version, the difference is located at the level of encoding ² ³ ° µ characters that can cause the error "ordinal not in range (128)" on some configurations ?

Example :

global uniteSs       ; uniteSs       = u"mm²"
global uniteVs       ; uniteVs       = u"mm³"
global uniteAs       ; uniteAs       = u"°"

replace to :

global uniteSs       ; uniteSs       = "mm"+iso8859(unichr(178))
global uniteVs       ; uniteVs       = "mm"+iso8859(unichr(179))
global uniteAs       ; uniteAs       = iso8859(unichr(176))

Files saved with this macro are incompatible with the files of the other versions.

Both versions can operate independently of the OS used.