1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-04 13:13:25 +03:00

0022312: Translation of french commentaries in OCCT files

This commit is contained in:
YSN
2011-10-27 07:50:55 +00:00
committed by bugmaster
parent b2342827fa
commit 0d9695538c
214 changed files with 8746 additions and 10449 deletions

View File

@@ -25,17 +25,17 @@
Standard_Boolean Draw_Interprete(char*); // Implemente dans draw.cxx
Standard_Boolean Draw_Interprete(char*); // Implement in draw.cxx
#define CLIENTWND 0
#define PROMPT "Command >> "
#define COMMANDSIZE 1000 // Nb caracteres maximun pour un commande
#define COMMANDSIZE 1000 // Max nb of characters for a command
// Definition des varaibles globales
// Definition of global variables
#ifdef STRICT
WNDPROC OldEditProc; // Sauvegarde la procedure standard de la fenetre d'edition (Sous Classement)
WNDPROC OldEditProc; // Save the standard procedure of the edition (sub-class)
#else
FARPROC OldEditProc;
#endif
@@ -70,7 +70,7 @@ HWND CreateCommandWindow(HWND hWnd, int nitem)
LONG APIENTRY CommandProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
{
HWND hWndEdit;
int index; // Nombre de caractere dans le buffer de hWndEdit
int index; // Nb of characters in the buffer of hWndEdit
MINMAXINFO* lpmmi;
switch(wMsg)
@@ -90,7 +90,7 @@ LONG APIENTRY CommandProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
case WM_SIZE :
hWndEdit = (HWND)GetWindowLong(hWnd, CLIENTWND);
MoveWindow(hWndEdit, 0, 0, LOWORD(lParam), HIWORD(lParam), TRUE);
// Place le curseur a la fin du buffer
// Place the cursor at the end of the buffer
index = SendMessage(hWnd, WM_GETTEXTLENGTH, 0l, 0l);
SendMessage(hWnd, EM_SETSEL, index, index);
break;
@@ -127,13 +127,13 @@ BOOL CommandCreateProc(HWND hWnd)
hWnd, 0,
hInstance, NULL);
// Enregistrement hWndEdit deans l'extra memory en 0 de CommandWindow
// Save hWndEdit in the extra memory in 0 of CommandWindow
if (hWndEdit)
SetWindowLong(hWnd, CLIENTWND, (LONG)hWndEdit);
// Sous Classement de la fenetre
// Sub-Class of the window
//-------
// Sauvegarde du pointeur sur la procedure existante
// Save the pointer on the existing procedure
#ifdef STRICT
#ifndef _WIN64
OldEditProc = (WNDPROC)GetWindowLong(hWndEdit, GWL_WNDPROC);
@@ -143,7 +143,7 @@ BOOL CommandCreateProc(HWND hWnd)
#else
OldEditProc = (FARPROC)GetWindowLong(hWndEdit, GWL_WNDPROC);
#endif
// Mise en place de la nouvelle fonction
// Implement the new function
#ifndef _WIN64
SetWindowLong(hWndEdit, GWL_WNDPROC, (LONG) EditProc);
#else
@@ -169,7 +169,7 @@ int GetCommand(HWND hWnd, char* buffer)
while ( again && nbLine > -1 && nbChar < COMMANDSIZE-1)
{
strcat(buffer, strrev(temp));
// Initialisation du 1er WORD de temp au nombre de caracteres a lire
// Initialization of the 1st WORD to the nb of characters to read
WORD* nbMaxChar = (WORD*)temp;
*nbMaxChar = COMMANDSIZE-1;
@@ -199,7 +199,7 @@ LONG APIENTRY EditProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
char buffer[COMMANDSIZE];
POINT pos;
BOOL rep;
static int nbline; // Taille du buffer de la fenetre d`edition
static int nbline; // Process the buffer of the edit window
int index;
switch(wMsg)
@@ -209,21 +209,21 @@ LONG APIENTRY EditProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
return 0l;
switch(LOWORD(wParam))
{
// Surcharge du caractere \n
// Overload of character \n
case 0x0d :
GetCommand(hWnd, buffer);
// Traitement standard
// Standard processing
CallWindowProc(OldEditProc, hWnd, wMsg, wParam, lParam);
// Affichage du PROMPT
// Display of PROMPT
rep = GetCaretPos(&pos);
SendMessage(hWnd, EM_REPLACESEL, 0, (LPARAM)PROMPT);
// Affiche la commande dans la console
// Display the command in the console
cout << buffer << endl;
/*if (Draw_Interprete(buffer+strlen(PROMPT))== -2)
DestroyProc(hWnd); */
strcpy(console_command, buffer+strlen(PROMPT));
console_semaphore = HAS_CONSOLE_COMMAND;
// Purge du buffer
// Purge the buffer
nbline = SendMessage(hWnd, EM_GETLINECOUNT, 0l, 0l);
if(nbline > 200)
{
@@ -232,7 +232,7 @@ LONG APIENTRY EditProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
index = SendMessage(hWnd, EM_LINEINDEX, 100, 0);
SendMessage(hWnd, EM_SETSEL, 0, index);
SendMessage(hWnd, WM_CUT, 0, 0);
// Place le curseur en fin de text
// Place the cursor at the end of text
index = SendMessage(hWnd, WM_GETTEXTLENGTH, 0l, 0l);
SendMessage(hWnd, EM_SETSEL, index, index);
}
@@ -241,7 +241,7 @@ LONG APIENTRY EditProc(HWND hWnd, UINT wMsg, WPARAM wParam, LONG lParam )
default :
if (IsAlphanumeric((Standard_Character)LOWORD(wParam)))
{
// Place le curseur en fin de texte avant affichage
// Place the cursor at the end of text before display
index = SendMessage(hWnd, WM_GETTEXTLENGTH, 0l, 0l);
SendMessage(hWnd, EM_SETSEL, index, index);
CallWindowProc(OldEditProc, hWnd, wMsg, wParam, lParam);

View File

@@ -237,7 +237,7 @@ static Standard_Integer cpulimit(Draw_Interpretor& di, Standard_Integer n, const
MDTV_CPU_LIMIT = atoi(a[1]);
MDTV_CPU_CURRENT = clock()/1000;
if (first) // Lancer le thread au 1er appel seulement.
if (first) // Launch the thread only at the 1st call.
{
first=0 ;
_beginthreadex(NULL,0,CpuFunc,NULL,0,&ThreadID);

View File

@@ -150,14 +150,14 @@ static void CommandDelete (ClientData clientData)
Draw_Interpretor::Draw_Interpretor() :
isAllocated(Standard_False)
{
// On ne cree pas tout de suite l'interpreteur tcl car s'il est detenu
// par une variable globale il est cree et ecrase avant le main().
// The tcl interpreter is not created immediately as it is kept
// by a global variable and created and deleted before the main().
myInterp = NULL;
}
//=======================================================================
//function : Init
//purpose : Il faut appeler cette fonction
//purpose : It is necessary to call this function
//=======================================================================
void Draw_Interpretor::Init()

View File

@@ -32,34 +32,6 @@
// - Draw_Appli is differently declared.
// *******************************************************************
// CKY 18 Juilet 1997
// *******************************************************************
// MAIN a la sauce WNT
// EXPLICATION : un MAIN sous NT, c est quelque chose ... different de sous UNIX
// ilya un tas de trucs a initialiser
// Deux aspects : le main et Draw_Appli
// le main est specifique : arguments, creation de "console"
// Draw_Appli aussi, mais comme certains peuvent le redefinir, et que
// NT ne permet pas cela, eh be il est duplique dans chaque main ...
// Ceci a l identique. Youpi
//
// Ce source comprend :
// - un main repris : WinMain, qui en particlier definit une "console"
// - un Draw_Appli repris
// - la plupart des ifdef WNT sont laisses pour memoire
// MAIS CE CODE N EST COMPILABLE QU EN NT
//
// MODE D EMPLOI
// Dans le source de l exec .cxx, Inclure ce gros paquet (NTMain.pxx)
// a la place des includes courants et du main, en ifdef WNT of course
//
// On laisse les includes specifiques ainsi que le Draw_InitAppli
// qui lui aussi est specifique
//
// ATTENTION, avant de faire umake, taper cette commande magique (?)
// setenv (WOK_EXETYPE) W
// *******************************************************************
#ifdef HAVE_CONFIG_H
# include <config.h>

View File

@@ -15,7 +15,7 @@
#include <Draw_Window.hxx>
#include <CommandWindow.h>
Standard_Boolean Draw_Interprete(char* command); // Implemente dans Draw.cxx
Standard_Boolean Draw_Interprete(char* command); // Implemented in Draw.cxx
extern Standard_Boolean Draw_IsConsoleSubsystem;
//extern "C" int compat_unlink(const char *fname); // Implemente dans TCL
@@ -59,14 +59,14 @@ LONG APIENTRY WndProc(HWND hWndFrame, UINT wMsg, WPARAM wParam, LONG lParam )
/*--------------------------------------------------------------------------*\
| CLIENT CREATE PROCEDURE
| Handler pour le message WM_CREATE. Creation de la fenetre de control MDI
| Handler for message WM_CREATE. Creation of control window MDI
|
\*--------------------------------------------------------------------------*/
BOOL CreateProc(HWND hWndFrame)
{
HWND hWnd;
// Enregistre le hWnd dans la fenetre principale dans extra memory en 0
// Save hWnd in the main window in extra memory in 0
if (hWnd = CreateMDIClientWindow(hWndFrame))
SetWindowLong(hWndFrame, CLIENTWND, (LONG)hWnd);
return(TRUE);
@@ -75,12 +75,12 @@ BOOL CreateProc(HWND hWndFrame)
/*--------------------------------------------------------------------------*\
| COMMAND PROCEDURE
| Handler pour le message WM_COMMAND
| Handler for message WM_COMMAND
|
\*--------------------------------------------------------------------------*/
BOOL CommandProc(HWND hWndFrame, WPARAM wParam, LPARAM lParam)
{
HWND hWndClient; // Handle sur la fenetre MDI
HWND hWndClient; // Handle on window MDI
HWND hWndActive;
hWndClient = (HWND)GetWindowLong(hWndFrame, CLIENTWND);
@@ -120,7 +120,7 @@ BOOL CommandProc(HWND hWndFrame, WPARAM wParam, LPARAM lParam)
/*--------------------------------------------------------------------------*\
| CLIENT DESTROY PROCEDURE
| Handler pour le message WM_DESTROY.
| Handler for message WM_DESTROY.
|
\*--------------------------------------------------------------------------*/
VOID DestroyProc(HWND hWnd)