diff --git a/docs/Notes/updates.md b/docs/Notes/updates.md index 221b2de5891c19..e505d03def1ee4 100644 --- a/docs/Notes/updates.md +++ b/docs/Notes/updates.md @@ -29,6 +29,7 @@ Read [**What’s new in 4D 20 R9**](https://blog.4d.com/en-whats-new-in-4d-20-R9 - New [4D AIKit component](../aikit/overview.md) enabling interaction with third-party AI APIs. - The following VP command callbacks now wait for all 4D custom functions to complete their calculations: [VP IMPORT DOCUMENT](../ViewPro/commands/vp-import-document.md), [VP IMPORT FORM BLOB](../ViewPro/commands/vp-import-from-blob.md), [VP IMPORT FROM OBJECT](../ViewPro/commands/vp-import-from-object.md), and [VP FLUSH COMMANDS](../ViewPro/commands/vp-flush-commands.md). - New [4D Netkit](https://developer.4d.com/4D-NetKit/) features to manage Google and Microsoft 365 calendars; ability to use the host web server for OAuth 2.0 authentication. +- 4D Write Pro Interface: New [integrated AI](../WritePro/writeprointerface.md#integrated-ai) to interact with **chatGTP** from your 4D Write Pro documents. - [**Fixed bug list**](https://bugs.4d.fr/fixedbugslist?version=20_R9): list of all bugs that have been fixed in 4D 20 R9. diff --git a/docs/REST/$compute.md b/docs/REST/$compute.md index b2df9b43b5cb02..068b6fb68822ec 100644 --- a/docs/REST/$compute.md +++ b/docs/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,7 +57,7 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: diff --git a/docs/WritePro/writeprointerface.md b/docs/WritePro/writeprointerface.md index 4895961689357d..ac5233b83b86b7 100644 --- a/docs/WritePro/writeprointerface.md +++ b/docs/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ A 4D developer can easily implement these palettes in their application. Thus, e The main [4D Write Pro Interface documentation](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) can be found in the *4D Design Reference manual*. -You will find below the Table Wizard configuration documentation. +You will find below: + +- the Table Wizard configuration documentation, +- the integrated A.I. documentation. ## Table Wizard @@ -295,4 +298,120 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### See also -[4D Write Pro - Table Wizard (tutorial video)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (tutorial video)](https://www.youtube.com/watch?v=2ChlTju-mtM) + + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + + + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + + +#### History + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/docs/assets/en/WritePro/ai-button.png b/docs/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/docs/assets/en/WritePro/ai-button.png differ diff --git a/docs/assets/en/WritePro/ai-interaction.png b/docs/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/docs/assets/en/WritePro/ai-interaction.png differ diff --git a/docs/assets/en/WritePro/ai-menu.png b/docs/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/docs/assets/en/WritePro/ai-menu.png differ diff --git a/docs/assets/en/WritePro/ai-resend.png b/docs/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/docs/assets/en/WritePro/ai-resend.png differ diff --git a/docs/assets/en/WritePro/ai-send.png b/docs/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/docs/assets/en/WritePro/ai-send.png differ diff --git a/docusaurus.config.js b/docusaurus.config.js index 49763078416f7a..d29c33232ac792 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -131,6 +131,13 @@ module.exports = { appId: 'OJ04C0M3CU', indexName: '4d', //contextualSearch: false + //added for command search + searchParameters: { + advancedSyntax: true, + queryType: 'prefixAll', // Priorise la chaine entiere + removeWordsIfNoResults: 'allOptional', // Recherche les elements individuels si aucun resultat + }, + // end }, docs: { sidebar: { diff --git a/i18n/es/docusaurus-plugin-content-docs/current/API/TCPConnectionClass.md b/i18n/es/docusaurus-plugin-content-docs/current/API/TCPConnectionClass.md index 6063fef87c3695..a0eb2ddbaf0c09 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/API/TCPConnectionClass.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/API/TCPConnectionClass.md @@ -3,49 +3,49 @@ id: TCPConnectionClass title: TCPConnection --- -The `TCPConnection` class allows you to manage Transmission Control Protocol (TCP) client connections to a [server](./TCPListenerClass.md), enabling you to send and receive data, and handle connection lifecycle events using callbacks. +La clase `TCPConnection` permite gestionar conexiones cliente del Protocolo de Control de Transmisión (TCP) a un [servidor](./TCPListenerClass.md), permitiendo enviar y recibir datos, y manejar eventos del ciclo de vida de la conexión mediante retrollamadas. -The `TCPConnection` class is available from the `4D` class store. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). +La clase `TCPConnection` está disponible en el class store `4D`. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). -All `TCPConnection` class functions are thread-safe. +Todas las funciones de la clase `TCPConnection` son hilo seguro. -Thanks to the standard 4D object *refcounting*, a TCPConnection is automatically released when it is no longer referenced. Consequently, the associated resources, are properly cleaned up without requiring explicit closure. +Gracias al *refcounting* estándar de los objetos 4D, una TCPConnection se libera automáticamente cuando deja de estar referenciada. En consecuencia, los recursos asociados, se limpian adecuadamente sin necesidad de un cierre explícito. -TCPConnection objects are released when no more references to them exist in memory. This typically occurs, for example, at the end of a method execution for local variables. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources). +Los objetos TCPConnection se liberan cuando ya no existen referencias a ellos en memoria. Esto ocurre típicamente, por ejemplo, al final de una ejecución de un método para variables locales. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources).
Historia -| Lanzamiento | Modificaciones | -| ----------- | ------------------------------------------------ | -| 20 R9 | New `listener`, `address`, and `port` attributes | -| 20 R8 | Clase añadida | +| Lanzamiento | Modificaciones | +| ----------- | ----------------------------------------------- | +| 20 R9 | Nuevos atributos `listener`, `address` y `port` | +| 20 R8 | Clase añadida |
### Ejemplos -The following examples demonstrate how to use the 4D.TCPConnection and 4D.TCPEvent classes to manage a TCP client connection, handle events, send data, and properly close the connection. Both synchronous and asynchronous examples are provided. +Los siguientes ejemplos demuestran cómo utilizar las clases 4D.TCPConnection y 4D.TCPEvent para gestionar una conexión cliente TCP, manejar eventos, enviar datos y cerrar correctamente la conexión. Se ofrecen ejemplos tanto síncronos como asíncronos. #### Ejemplo sincrónico -This example shows how to establish a connection, send data, and shut it down using a simple object for configuration: +Este ejemplo muestra cómo establecer una conexión, enviar datos y cerrarla utilizando un simple objeto para la configuración: ```4d var $domain : Text := "127.0.0.1" var $port : Integer := 10000 -var $options : Object := New object() // Configuration object +var $options : Object := New object() // Objeto de configuración var $tcpClient : 4D.TCPConnection var $message : Text := "test message" -// Open a connection +// Abrir una conexión $tcpClient := 4D.TCPConnection.new($domain; $port; $options) -// Send data +// Enviar datos var $blobData : Blob TEXT TO BLOB($message; $blobData; UTF8 text without length) $tcpClient.send($blobData) -// Shutdown +// Apagar $tcpClient.shutdown() $tcpClient.wait(0) @@ -53,59 +53,59 @@ $tcpClient.wait(0) #### Ejemplo asincrónico -This example defines a class that handles the connection lifecycle and events, showcasing how to work asynchronously: +Este ejemplo define una clase que maneja el ciclo de vida de la conexión y los eventos, mostrando cómo trabajar de forma asíncrona: ```4d -// Class definition: cs.MyAsyncTCPConnection +// Definición de la clase: cs.MyAsyncTCPConnection Class constructor($url : Text; $port : Integer) This.connection := Null This.url := $url This.port := $port -// Connect to one of the servers launched inside workers +// Conectarse a uno de los servidores lanzados dentro de los workers Function connect() This.connection := 4D.TCPConnection.new(This.url; This.port; This) -// Disconnect from the server +// Desconectarse del servidor Function disconnect() This.connection.shutdown() This.connection := Null -// Send data to the server +// Enviar datos al servidor Function getInfo() var $blob : Blob - TEXT TO BLOB("Information"; $blob) + TEXT TO BLOB("Información"; $blob) This.connection.send($blob) -// Callback called when the connection is successfully established +// Retrollamada cuando la conexión se ha establecido correctamente Function onConnection($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection established") + ALERT("Conexión establecida") -// Callback called when the connection is properly closed +// Retrollamada cuando la conexión se ha cerrado correctamente Function onShutdown($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection closed") + ALERT("Conexión cerrada") -// Callback called when receiving data from the server +// Retrollamada cuando se reciben datos del servidor Function onData($connection : 4D.TCPConnection; $event : 4D.TCPEvent) ALERT(BLOB to text($event.data; UTF8 text without length)) - //Warning: There's no guarantee you'll receive all the data you need in a single network packet. + //Atención: no hay garantía de que reciba todos los datos que necesita en un solo paquete de red. -// Callback called when the connection is closed unexpectedly +// Retrollamada cuando la conexión se cierra inesperadamente Function onError($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection error") + ALERT("Error de conexión") -// Callback called after onShutdown/onError just before the TCPConnection object is released +// Retrollamada después de onShutdown/onError justo antes de que el objeto TCPConnection sea liberado Function onTerminate($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection terminated") + ALERT("Conexión terminada") ``` ##### Ejemplo de uso -Create a new method named AsyncTCP, to initialize and manage the TCP connection: +Crea un nuevo método llamado AsyncTCP, para inicializar y gestionar la conexión TCP: ```4d var $myObject : cs.MyAsyncTCPConnection @@ -116,7 +116,7 @@ $myObject.disconnect() ``` -Call the AsyncTCP method in a worker: +Llama al método AsyncTCP en un worker: ```4d CALL WORKER("new process"; "Async_TCP") @@ -125,9 +125,9 @@ CALL WORKER("new process"; "Async_TCP") ### Objeto TCPConnection -A TCPConnection object is a non-sharable object. +Un objeto TCPConnection es un objeto no compartible. -TCPConnection objects provide the following properties and functions: +Los objetos TCPConnection ofrecen las siguientes propiedades y funciones: | | | --------------------------------------------------------------------------------------------------------------------- | @@ -151,10 +151,10 @@ TCPConnection objects provide the following properties and functions: | Parámetros | Tipo | | Descripción | | ------------- | ------------- | --------------------------- | ------------------------------------------------------------- | -| serverAddress | Text | -> | Domain name or IP address of the server | +| serverAddress | Text | -> | Nombre de dominio o dirección IP del servidor | | serverPort | Integer | -> | Número de puerto del servidor | | options | Object | -> | Configuración [opciones](#options-parameter) para la conexión | -| Resultado | TCPConnection | <- | New TCPConnection object | +| Resultado | TCPConnection | <- | Nuevo objeto TCPConnection | @@ -166,33 +166,33 @@ La función `4D.TCPConnection.new()` -## .dirección +## .address **address** : Text #### Descripción -The `.address` property contains the IP addess or domain name of the remote machine. +La propiedad `.address` contiene la dirección IP o el nombre de dominio de la máquina remota. @@ -220,7 +220,7 @@ The `.address` property contains the #### Descripción -La propiedad `.closed` contiene si la conexión está cerrada. Returns `true` if the connection is closed, either due to an error, a call to `shutdown()`, or closure by the server. +La propiedad `.closed` contiene si la conexión está cerrada. Devuelve `true` si la conexión se ha cerrado, ya sea debido a un error, una llamada a `shutdown()`, o el cierre por parte del servidor. @@ -251,7 +251,7 @@ La propiedad `.errors` contiene una co #### Descripción -The `.listener` property contains the [`TCPListener`](./TCPListenerClass.md) object that created the `TCPConnection`, if any. Esta propiedad es de **solo lectura**. +La propiedad `.listener` contiene el objeto [`TCPListener`](./TCPListenerClass.md) que creó la `TCPConnection`, si existe. Esta propiedad es de **solo lectura**. @@ -275,7 +275,7 @@ La propiedad `.noDelay` contiene si e #### Descripción -The `.port` property contains the port number of the remote machine. Esta propiedad es de **solo lectura**. +La propiedad `.port` contiene el número de puerto de la máquina remota. Esta propiedad es de **solo lectura**. @@ -295,7 +295,7 @@ The `.port` property contains the port n #### Descripción -La función `send()` envía datos al servidor. If the connection is not established yet, the data is sent once the connection is established. +La función `send()` envía datos al servidor. Si la conexión no se ha establecido todavía, los datos se envían una vez que se ha establecido la conexión. @@ -339,7 +339,7 @@ La función `wait()` espera hasta que :::note -During the `.wait()` execution, callback functions are executed, whether they originate from other `SystemWorker` instances. Puede salir de un `.wait()` llamando a [`shutdown()`](#shutdown) desde una retrollamada. +Durante la ejecución de `.wait()`, se ejecutan funciones de callback, tanto si proceden de otras instancias de `SystemWorker`. Puede salir de un `.wait()` llamando a [`shutdown()`](#shutdown) desde una retrollamada. ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/current/API/TCPListenerClass.md b/i18n/es/docusaurus-plugin-content-docs/current/API/TCPListenerClass.md index 4110f9bc5da8d5..aab3f8ca4fc47d 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/API/TCPListenerClass.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/API/TCPListenerClass.md @@ -100,12 +100,12 @@ Callback functions receive up to two parameters: | Parámetros | Tipo | Descripción | | ---------- | ------------------------------------------- | ----------------------------------------------------- | | $listener | [`TCPListener` object](#tcplistener-object) | The current TCP listener instance. | -| $event | [objeto `TCPEvent`](#tcpevent-object) | Contains information about the event. | +| $event | [objeto `TCPEvent`](#tcpevent-object) | Contiene información sobre el evento. | -**Sequence of Callback Calls:** +**Secuencia de retrollamadas:** 1. `onConnection` is triggered each time a connection is established. -2. `onError` is triggered if an error occurs. +2. `onError` se activa si se produce un error. 3. `onTerminate` is always triggered just before a connection is terminated. #### Objeto TCPEvent diff --git a/i18n/es/docusaurus-plugin-content-docs/current/Desktop/building.md b/i18n/es/docusaurus-plugin-content-docs/current/Desktop/building.md index 0a7080c2e9c9d6..e37edb79e01f6e 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/Desktop/building.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/Desktop/building.md @@ -534,7 +534,7 @@ As soon as the "Build an evaluation application" option is enabled, deployment l :::note Notas - The [`License info`](../commands/license-info.md) command allows you to know the application license type (*.attributes* collection) and its expiration date (*.expirationDate* object). -- The BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) xml key allows you to manage evaluation versions. +- La llave xml BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) permite gestionar las versiones de evaluación. - The [`CHANGE LICENCES`](../commands-legacy/change-licenses.md) command does nothing when called from an evaluation version. ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/current/Desktop/labels.md b/i18n/es/docusaurus-plugin-content-docs/current/Desktop/labels.md index 99b0be778f8df2..2332744b4d2c36 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/Desktop/labels.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/Desktop/labels.md @@ -154,7 +154,7 @@ The **For each: Record or Label** options are used to specify whether to run the ::: -- **Layout preview**: Provides a reduced view of how an entire page of labels will look, based on the dimensions you enter in the Label editor. The page preview also reflects the paper size selected in the Print Setup dialog box. You can also use this area to designate the first label on the page to be printed (this option only affects the first sheet in the case of multi-page printing). This can be useful, for example, when you want to print on a sheet of adhesive labels, part of which has already been used. You can also select the first label on the page to be printed by clicking on it: +- **Layout preview**: Provides a reduced view of how an entire page of labels will look, based on the dimensions you enter in the Label editor. The page preview also reflects the paper size selected in the Print Setup dialog box. También puede utilizar esta zona para designar la primera etiqueta de la página que se va a imprimir (esta opción sólo afecta a la primera hoja en caso de impresión multipágina). This can be useful, for example, when you want to print on a sheet of adhesive labels, part of which has already been used. You can also select the first label on the page to be printed by clicking on it: ![](../assets/en/Desktop/label-start.png) diff --git a/i18n/es/docusaurus-plugin-content-docs/current/Notes/updates.md b/i18n/es/docusaurus-plugin-content-docs/current/Notes/updates.md index 53d04d7a9a5d5f..1ebccd8ef33628 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/Notes/updates.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/Notes/updates.md @@ -28,6 +28,7 @@ Read [**What’s new in 4D 20 R9**](https://blog.4d.com/en-whats-new-in-4d-20-R9 - New [4D AIKit component](../aikit/overview.md) enabling interaction with third-party AI APIs. - The following VP command callbacks now wait for all 4D custom functions to complete their calculations: [VP IMPORT DOCUMENT](../ViewPro/commands/vp-import-document.md), [VP IMPORT FORM BLOB](../ViewPro/commands/vp-import-from-blob.md), [VP IMPORT FROM OBJECT](../ViewPro/commands/vp-import-from-object.md), and [VP FLUSH COMMANDS](../ViewPro/commands/vp-flush-commands.md). - New [4D Netkit](https://developer.4d.com/4D-NetKit/) features to manage Google and Microsoft 365 calendars; ability to use the host web server for OAuth 2.0 authentication. +- 4D Write Pro Interface: New [integrated AI](../WritePro/writeprointerface.md#integrated-ai) to interact with **chatGTP** from your 4D Write Pro documents. - [**Fixed bug list**](https://bugs.4d.fr/fixedbugslist?version=20_R9): list of all bugs that have been fixed in 4D 20 R9. ## 4D 20 R8 diff --git a/i18n/es/docusaurus-plugin-content-docs/current/REST/$compute.md b/i18n/es/docusaurus-plugin-content-docs/current/REST/$compute.md index e53ec7556746d2..586bd2b75ec437 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/REST/$compute.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/REST/$compute.md @@ -36,7 +36,7 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri **Response**: -``` +```js { "salary": { "count": 4, @@ -54,7 +54,7 @@ Si desea obtener todos los cálculos de un atributo de tipo String, puede escrib **Response**: -``` +```js { "salary": { "count": 4, @@ -70,7 +70,7 @@ Si desea obtener un cálculo con un atributo, escriba lo siguiente: **Response**: -`235000` +`335000` Si desea realizar un cálculo con un atributo Objeto, escriba lo siguiente: diff --git a/i18n/es/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md b/i18n/es/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md index e570e145ba0b06..7b0135b465f076 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Un desarrollador 4D puede implementar fácilmente estas paletas en su aplicació La documentación principal de [la interfaz de 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se encuentra en el manual *Diseño 4D*. -A continuación encontrará la documentación de configuración del Asistente para tablas. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Asistente de tablas @@ -294,4 +297,114 @@ Por cada atributo usado en su archivo JSON (encabezado, datos, arrastre, resumen #### Ver también -[4D Write Pro - Asistente para tablas (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Asistente para tablas (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Histórico + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/current/commands/process-activity.md b/i18n/es/docusaurus-plugin-content-docs/current/commands/process-activity.md index 736ea728d131b1..0b22ebf0da346e 100644 --- a/i18n/es/docusaurus-plugin-content-docs/current/commands/process-activity.md +++ b/i18n/es/docusaurus-plugin-content-docs/current/commands/process-activity.md @@ -46,7 +46,7 @@ On 4D Server, you can filter information to be returned using the optional *sess :::note -When executed on 4D in remote or local mode, `Process activity` always returns the list of running processes (*sessionID* and *options* parameters are ignored). +Cuando se ejecuta en 4D en modo remoto o local, `Process activity` siempre devuelve la lista de procesos en ejecución (se ignoran los parámetros *sessionID* y *options*). ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-19/REST/$compute.md b/i18n/es/docusaurus-plugin-content-docs/version-19/REST/$compute.md index 1098ddda697ea0..fccb1376df040b 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-19/REST/$compute.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-19/REST/$compute.md @@ -38,8 +38,7 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri `GET /rest/Employee/salary/?$compute=$all` **Respuesta**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri } ```` -Si desea obtener todos los cálculos de un atributo de tipo String, puede escribir: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Respuesta**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Si desea obtener un cálculo con un atributo, escriba lo siguiente: **Respuesta**: -`235000` +`335000` Si desea realizar un cálculo con un atributo Objeto, escriba lo siguiente: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/API/TCPConnectionClass.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/API/TCPConnectionClass.md index 71d7f3d9b61daa..6222723d127c02 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/API/TCPConnectionClass.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/API/TCPConnectionClass.md @@ -5,13 +5,13 @@ title: TCPConnection The `TCPConnection` class allows you to manage Transmission Control Protocol (TCP) client connections to a server, enabling you to send and receive data, and handle connection lifecycle events using callbacks. -The `TCPConnection` class is available from the `4D` class store. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). +La clase `TCPConnection` está disponible en el class store `4D`. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). -All `TCPConnection` class functions are thread-safe. +Todas las funciones de la clase `TCPConnection` son hilo seguro. -Thanks to the standard 4D object *refcounting*, a TCPConnection is automatically released when it is no longer referenced. Consequently, the associated resources, are properly cleaned up without requiring explicit closure. +Gracias al *refcounting* estándar de los objetos 4D, una TCPConnection se libera automáticamente cuando deja de estar referenciada. En consecuencia, los recursos asociados, se limpian adecuadamente sin necesidad de un cierre explícito. -TCPConnection objects are released when no more references to them exist in memory. This typically occurs, for example, at the end of a method execution for local variables. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources). +Los objetos TCPConnection se liberan cuando ya no existen referencias a ellos en memoria. Esto ocurre típicamente, por ejemplo, al final de una ejecución de un método para variables locales. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources).
Historia @@ -23,28 +23,28 @@ TCPConnection objects are released when no more references to them exist in memo ### Ejemplos -The following examples demonstrate how to use the 4D.TCPConnection and 4D.TCPEvent classes to manage a TCP client connection, handle events, send data, and properly close the connection. Both synchronous and asynchronous examples are provided. +Los siguientes ejemplos demuestran cómo utilizar las clases 4D.TCPConnection y 4D.TCPEvent para gestionar una conexión cliente TCP, manejar eventos, enviar datos y cerrar correctamente la conexión. Se ofrecen ejemplos tanto síncronos como asíncronos. #### Ejemplo sincrónico -This example shows how to establish a connection, send data, and shut it down using a simple object for configuration: +Este ejemplo muestra cómo establecer una conexión, enviar datos y cerrarla utilizando un simple objeto para la configuración: ```4d var $domain : Text := "127.0.0.1" var $port : Integer := 10000 -var $options : Object := New object() // Configuration object +var $options : Object := New object() // Objeto de configuración var $tcpClient : 4D.TCPConnection var $message : Text := "test message" -// Open a connection +// Abrir una conexión $tcpClient := 4D.TCPConnection.new($domain; $port; $options) -// Send data +// Enviar datos var $blobData : Blob TEXT TO BLOB($message; $blobData; UTF8 text without length) $tcpClient.send($blobData) -// Shutdown +// Apagar $tcpClient.shutdown() $tcpClient.wait(0) @@ -52,59 +52,59 @@ $tcpClient.wait(0) #### Ejemplo asincrónico -This example defines a class that handles the connection lifecycle and events, showcasing how to work asynchronously: +Este ejemplo define una clase que maneja el ciclo de vida de la conexión y los eventos, mostrando cómo trabajar de forma asíncrona: ```4d -// Class definition: cs.MyAsyncTCPConnection +// Definición de la clase: cs.MyAsyncTCPConnection Class constructor($url : Text; $port : Integer) This.connection := Null This.url := $url This.port := $port -// Connect to one of the servers launched inside workers +// Conectarse a uno de los servidores lanzados dentro de los workers Function connect() This.connection := 4D.TCPConnection.new(This.url; This.port; This) -// Disconnect from the server +// Desconectarse del servidor Function disconnect() This.connection.shutdown() This.connection := Null -// Send data to the server +// Enviar datos al servidor Function getInfo() var $blob : Blob - TEXT TO BLOB("Information"; $blob) + TEXT TO BLOB("Información"; $blob) This.connection.send($blob) -// Callback called when the connection is successfully established +// Retrollamada cuando la conexión se ha establecido correctamente Function onConnection($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection established") + ALERT("Conexión establecida") -// Callback called when the connection is properly closed +// Retrollamada cuando la conexión se ha cerrado correctamente Function onShutdown($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection closed") + ALERT("Conexión cerrada") -// Callback called when receiving data from the server +// Retrollamada cuando se reciben datos del servidor Function onData($connection : 4D.TCPConnection; $event : 4D.TCPEvent) ALERT(BLOB to text($event.data; UTF8 text without length)) - //Warning: There's no guarantee you'll receive all the data you need in a single network packet. + //Atención: no hay garantía de que reciba todos los datos que necesita en un solo paquete de red. -// Callback called when the connection is closed unexpectedly +// Retrollamada cuando la conexión se cierra inesperadamente Function onError($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection error") + ALERT("Error de conexión") -// Callback called after onShutdown/onError just before the TCPConnection object is released +// Retrollamada después de onShutdown/onError justo antes de que el objeto TCPConnection sea liberado Function onTerminate($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection terminated") + ALERT("Conexión terminada") ``` ##### Ejemplo de uso -Create a new method named AsyncTCP, to initialize and manage the TCP connection: +Crea un nuevo método llamado AsyncTCP, para inicializar y gestionar la conexión TCP: ```4d var $myObject : cs.MyAsyncTCPConnection @@ -115,7 +115,7 @@ $myObject.disconnect() ``` -Call the AsyncTCP method in a worker: +Llama al método AsyncTCP en un worker: ```4d CALL WORKER("new process"; "Async_TCP") @@ -124,9 +124,9 @@ CALL WORKER("new process"; "Async_TCP") ### Objeto TCPConnection -A TCPConnection object is a non-sharable object. +Un objeto TCPConnection es un objeto no compartible. -TCPConnection objects provide the following properties and functions: +Los objetos TCPConnection ofrecen las siguientes propiedades y funciones: | | | --------------------------------------------------------------------------------------------------------------------- | @@ -147,10 +147,10 @@ TCPConnection objects provide the following properties and functions: | Parámetros | Tipo | | Descripción | | ------------- | ------------- | --------------------------- | ------------------------------------------------------------- | -| serverAddress | Text | -> | Domain name or IP address of the server | +| serverAddress | Text | -> | Nombre de dominio o dirección IP del servidor | | serverPort | Integer | -> | Número de puerto del servidor | | options | Object | -> | Configuración [opciones](#options-parameter) para la conexión | -| Resultado | TCPConnection | <- | New TCPConnection object | +| Resultado | TCPConnection | <- | Nuevo objeto TCPConnection | @@ -162,32 +162,32 @@ La función `4D.TCPConnection.new()` si la conexión está cerrada. Returns `true` if the connection is closed, either due to an error, a call to `shutdown()`, or closure by the server. +La propiedad `.closed` contiene si la conexión está cerrada. Devuelve `true` si la conexión se ha cerrado, ya sea debido a un error, una llamada a `shutdown()`, o el cierre por parte del servidor. @@ -254,7 +254,7 @@ La propiedad `.noDelay` contiene si e #### Descripción -La función `send()` envía datos al servidor. If the connection is not established yet, the data is sent once the connection is established. +La función `send()` envía datos al servidor. Si la conexión no se ha establecido todavía, los datos se envían una vez que se ha establecido la conexión. diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/Desktop/building.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/Desktop/building.md index beb5949cfd07df..8ed958b5576490 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/Desktop/building.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/Desktop/building.md @@ -552,7 +552,7 @@ As soon as the "Build an evaluation application" option is enabled, deployment l :::note Notas - The [`License info`](../commands/license-info.md) command allows you to know the application license type (*.attributes* collection) and its expiration date (*.expirationDate* object). -- The BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) xml key allows you to manage evaluation versions. +- La llave xml BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) permite gestionar las versiones de evaluación. - The [`CHANGE LICENCES`](../commands-legacy/change-licenses.md) command does nothing when called from an evaluation version. ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md index e53ec7556746d2..67b4ff5e934eef 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md @@ -36,7 +36,7 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri **Response**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Si desea obtener todos los cálculos de un atributo de tipo String, puede escrib **Response**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Si desea obtener un cálculo con un atributo, escriba lo siguiente: **Response**: -`235000` +`335000` Si desea realizar un cálculo con un atributo Objeto, escriba lo siguiente: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/commands/process-activity.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/commands/process-activity.md index 736ea728d131b1..0b22ebf0da346e 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R8/commands/process-activity.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R8/commands/process-activity.md @@ -46,7 +46,7 @@ On 4D Server, you can filter information to be returned using the optional *sess :::note -When executed on 4D in remote or local mode, `Process activity` always returns the list of running processes (*sessionID* and *options* parameters are ignored). +Cuando se ejecuta en 4D en modo remoto o local, `Process activity` siempre devuelve la lista de procesos en ejecución (se ignoran los parámetros *sessionID* y *options*). ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPConnectionClass.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPConnectionClass.md index db913292c8d1bf..9adc6d8d2fbcc7 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPConnectionClass.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPConnectionClass.md @@ -3,49 +3,49 @@ id: TCPConnectionClass title: TCPConnection --- -The `TCPConnection` class allows you to manage Transmission Control Protocol (TCP) client connections to a [server](./TCPListenerClass.md), enabling you to send and receive data, and handle connection lifecycle events using callbacks. +La clase `TCPConnection` permite gestionar conexiones cliente del Protocolo de Control de Transmisión (TCP) a un [servidor](./TCPListenerClass.md), permitiendo enviar y recibir datos, y manejar eventos del ciclo de vida de la conexión mediante retrollamadas. -The `TCPConnection` class is available from the `4D` class store. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). +La clase `TCPConnection` está disponible en el class store `4D`. Puede crear una conexión TCP utilizando la función [4D.TCPConnection.new()](#4dtcpconnectionnew) que devuelve un [TCPConnection object](#tcpconnection-object). -All `TCPConnection` class functions are thread-safe. +Todas las funciones de la clase `TCPConnection` son hilo seguro. -Thanks to the standard 4D object *refcounting*, a TCPConnection is automatically released when it is no longer referenced. Consequently, the associated resources, are properly cleaned up without requiring explicit closure. +Gracias al *refcounting* estándar de los objetos 4D, una TCPConnection se libera automáticamente cuando deja de estar referenciada. En consecuencia, los recursos asociados, se limpian adecuadamente sin necesidad de un cierre explícito. -TCPConnection objects are released when no more references to them exist in memory. This typically occurs, for example, at the end of a method execution for local variables. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources). +Los objetos TCPConnection se liberan cuando ya no existen referencias a ellos en memoria. Esto ocurre típicamente, por ejemplo, al final de una ejecución de un método para variables locales. If you want to "force" the closure of a connection at any moment, [**nullify** its references by setting them to **Null**](../Concepts/dt_object.md#resources).
Historia -| Lanzamiento | Modificaciones | -| ----------- | ------------------------------------------------ | -| 20 R9 | New `listener`, `address`, and `port` attributes | -| 20 R8 | Clase añadida | +| Lanzamiento | Modificaciones | +| ----------- | ----------------------------------------------- | +| 20 R9 | Nuevos atributos `listener`, `address` y `port` | +| 20 R8 | Clase añadida |
### Ejemplos -The following examples demonstrate how to use the 4D.TCPConnection and 4D.TCPEvent classes to manage a TCP client connection, handle events, send data, and properly close the connection. Both synchronous and asynchronous examples are provided. +Los siguientes ejemplos demuestran cómo utilizar las clases 4D.TCPConnection y 4D.TCPEvent para gestionar una conexión cliente TCP, manejar eventos, enviar datos y cerrar correctamente la conexión. Se ofrecen ejemplos tanto síncronos como asíncronos. #### Ejemplo sincrónico -This example shows how to establish a connection, send data, and shut it down using a simple object for configuration: +Este ejemplo muestra cómo establecer una conexión, enviar datos y cerrarla utilizando un simple objeto para la configuración: ```4d var $domain : Text := "127.0.0.1" var $port : Integer := 10000 -var $options : Object := New object() // Configuration object +var $options : Object := New object() // Objeto de configuración var $tcpClient : 4D.TCPConnection var $message : Text := "test message" -// Open a connection +// Abrir una conexión $tcpClient := 4D.TCPConnection.new($domain; $port; $options) -// Send data +// Enviar datos var $blobData : Blob TEXT TO BLOB($message; $blobData; UTF8 text without length) $tcpClient.send($blobData) -// Shutdown +// Apagar $tcpClient.shutdown() $tcpClient.wait(0) @@ -53,59 +53,59 @@ $tcpClient.wait(0) #### Ejemplo asincrónico -This example defines a class that handles the connection lifecycle and events, showcasing how to work asynchronously: +Este ejemplo define una clase que maneja el ciclo de vida de la conexión y los eventos, mostrando cómo trabajar de forma asíncrona: ```4d -// Class definition: cs.MyAsyncTCPConnection +// Definición de la clase: cs.MyAsyncTCPConnection Class constructor($url : Text; $port : Integer) This.connection := Null This.url := $url This.port := $port -// Connect to one of the servers launched inside workers +// Conectarse a uno de los servidores lanzados dentro de los workers Function connect() This.connection := 4D.TCPConnection.new(This.url; This.port; This) -// Disconnect from the server +// Desconectarse del servidor Function disconnect() This.connection.shutdown() This.connection := Null -// Send data to the server +// Enviar datos al servidor Function getInfo() var $blob : Blob - TEXT TO BLOB("Information"; $blob) + TEXT TO BLOB("Información"; $blob) This.connection.send($blob) -// Callback called when the connection is successfully established +// Retrollamada cuando la conexión se ha establecido correctamente Function onConnection($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection established") + ALERT("Conexión establecida") -// Callback called when the connection is properly closed +// Retrollamada cuando la conexión se ha cerrado correctamente Function onShutdown($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection closed") + ALERT("Conexión cerrada") -// Callback called when receiving data from the server +// Retrollamada cuando se reciben datos del servidor Function onData($connection : 4D.TCPConnection; $event : 4D.TCPEvent) ALERT(BLOB to text($event.data; UTF8 text without length)) - //Warning: There's no guarantee you'll receive all the data you need in a single network packet. + //Atención: no hay garantía de que reciba todos los datos que necesita en un solo paquete de red. -// Callback called when the connection is closed unexpectedly +// Retrollamada cuando la conexión se cierra inesperadamente Function onError($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection error") + ALERT("Error de conexión") -// Callback called after onShutdown/onError just before the TCPConnection object is released +// Retrollamada después de onShutdown/onError justo antes de que el objeto TCPConnection sea liberado Function onTerminate($connection : 4D.TCPConnection; $event : 4D.TCPEvent) - ALERT("Connection terminated") + ALERT("Conexión terminada") ``` ##### Ejemplo de uso -Create a new method named AsyncTCP, to initialize and manage the TCP connection: +Crea un nuevo método llamado AsyncTCP, para inicializar y gestionar la conexión TCP: ```4d var $myObject : cs.MyAsyncTCPConnection @@ -116,7 +116,7 @@ $myObject.disconnect() ``` -Call the AsyncTCP method in a worker: +Llama al método AsyncTCP en un worker: ```4d CALL WORKER("new process"; "Async_TCP") @@ -125,9 +125,9 @@ CALL WORKER("new process"; "Async_TCP") ### Objeto TCPConnection -A TCPConnection object is a non-sharable object. +Un objeto TCPConnection es un objeto no compartible. -TCPConnection objects provide the following properties and functions: +Los objetos TCPConnection ofrecen las siguientes propiedades y funciones: | | | --------------------------------------------------------------------------------------------------------------------- | @@ -151,10 +151,10 @@ TCPConnection objects provide the following properties and functions: | Parámetros | Tipo | | Descripción | | ------------- | ------------- | --------------------------- | ------------------------------------------------------------- | -| serverAddress | Text | -> | Domain name or IP address of the server | +| serverAddress | Text | -> | Nombre de dominio o dirección IP del servidor | | serverPort | Integer | -> | Número de puerto del servidor | | options | Object | -> | Configuración [opciones](#options-parameter) para la conexión | -| Resultado | TCPConnection | <- | New TCPConnection object | +| Resultado | TCPConnection | <- | Nuevo objeto TCPConnection | @@ -166,32 +166,32 @@ La función `4D.TCPConnection.new()` -## .dirección +## .address **address** : Text #### Descripción -The `.address` property contains the IP addess or domain name of the remote machine. +La propiedad `.address` contiene la dirección IP o el nombre de dominio de la máquina remota. @@ -219,7 +219,7 @@ The `.address` property contains the #### Descripción -La propiedad `.closed` contiene si la conexión está cerrada. Returns `true` if the connection is closed, either due to an error, a call to `shutdown()`, or closure by the server. +La propiedad `.closed` contiene si la conexión está cerrada. Devuelve `true` si la conexión se ha cerrado, ya sea debido a un error, una llamada a `shutdown()`, o el cierre por parte del servidor. @@ -250,7 +250,7 @@ La propiedad `.errors` contiene una co #### Descripción -The `.listener` property contains the [`TCPListener`](./TCPListenerClass.md) object that created the `TCPConnection`, if any. Esta propiedad es de **solo lectura**. +La propiedad `.listener` contiene el objeto [`TCPListener`](./TCPListenerClass.md) que creó la `TCPConnection`, si existe. Esta propiedad es de **solo lectura**. @@ -274,7 +274,7 @@ La propiedad `.noDelay` contiene si e #### Descripción -The `.port` property contains the port number of the remote machine. Esta propiedad es de **solo lectura**. +La propiedad `.port` contiene el número de puerto de la máquina remota. Esta propiedad es de **solo lectura**. @@ -294,7 +294,7 @@ The `.port` property contains the port n #### Descripción -La función `send()` envía datos al servidor. If the connection is not established yet, the data is sent once the connection is established. +La función `send()` envía datos al servidor. Si la conexión no se ha establecido todavía, los datos se envían una vez que se ha establecido la conexión. diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPListenerClass.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPListenerClass.md index 4110f9bc5da8d5..aab3f8ca4fc47d 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPListenerClass.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/API/TCPListenerClass.md @@ -100,12 +100,12 @@ Callback functions receive up to two parameters: | Parámetros | Tipo | Descripción | | ---------- | ------------------------------------------- | ----------------------------------------------------- | | $listener | [`TCPListener` object](#tcplistener-object) | The current TCP listener instance. | -| $event | [objeto `TCPEvent`](#tcpevent-object) | Contains information about the event. | +| $event | [objeto `TCPEvent`](#tcpevent-object) | Contiene información sobre el evento. | -**Sequence of Callback Calls:** +**Secuencia de retrollamadas:** 1. `onConnection` is triggered each time a connection is established. -2. `onError` is triggered if an error occurs. +2. `onError` se activa si se produce un error. 3. `onTerminate` is always triggered just before a connection is terminated. #### Objeto TCPEvent diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/building.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/building.md index 0a7080c2e9c9d6..e37edb79e01f6e 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/building.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/building.md @@ -534,7 +534,7 @@ As soon as the "Build an evaluation application" option is enabled, deployment l :::note Notas - The [`License info`](../commands/license-info.md) command allows you to know the application license type (*.attributes* collection) and its expiration date (*.expirationDate* object). -- The BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) xml key allows you to manage evaluation versions. +- La llave xml BuildApplication [`EvaluationMode`](https://doc.4d.com/4Dv20R8/4D/20-R8/EvaluationMode.300-7542468.en.html) permite gestionar las versiones de evaluación. - The [`CHANGE LICENCES`](../commands-legacy/change-licenses.md) command does nothing when called from an evaluation version. ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/labels.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/labels.md index 99b0be778f8df2..2332744b4d2c36 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/labels.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/Desktop/labels.md @@ -154,7 +154,7 @@ The **For each: Record or Label** options are used to specify whether to run the ::: -- **Layout preview**: Provides a reduced view of how an entire page of labels will look, based on the dimensions you enter in the Label editor. The page preview also reflects the paper size selected in the Print Setup dialog box. You can also use this area to designate the first label on the page to be printed (this option only affects the first sheet in the case of multi-page printing). This can be useful, for example, when you want to print on a sheet of adhesive labels, part of which has already been used. You can also select the first label on the page to be printed by clicking on it: +- **Layout preview**: Provides a reduced view of how an entire page of labels will look, based on the dimensions you enter in the Label editor. The page preview also reflects the paper size selected in the Print Setup dialog box. También puede utilizar esta zona para designar la primera etiqueta de la página que se va a imprimir (esta opción sólo afecta a la primera hoja en caso de impresión multipágina). This can be useful, for example, when you want to print on a sheet of adhesive labels, part of which has already been used. You can also select the first label on the page to be printed by clicking on it: ![](../assets/en/Desktop/label-start.png) diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md index e53ec7556746d2..67b4ff5e934eef 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md @@ -36,7 +36,7 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri **Response**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Si desea obtener todos los cálculos de un atributo de tipo String, puede escrib **Response**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Si desea obtener un cálculo con un atributo, escriba lo siguiente: **Response**: -`235000` +`335000` Si desea realizar un cálculo con un atributo Objeto, escriba lo siguiente: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md index e570e145ba0b06..7b0135b465f076 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Un desarrollador 4D puede implementar fácilmente estas paletas en su aplicació La documentación principal de [la interfaz de 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se encuentra en el manual *Diseño 4D*. -A continuación encontrará la documentación de configuración del Asistente para tablas. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Asistente de tablas @@ -294,4 +297,114 @@ Por cada atributo usado en su archivo JSON (encabezado, datos, arrastre, resumen #### Ver también -[4D Write Pro - Asistente para tablas (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Asistente para tablas (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Histórico + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png differ diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/commands/process-activity.md b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/commands/process-activity.md index 51e158a282a70b..d295d8e4ca0646 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20-R9/commands/process-activity.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20-R9/commands/process-activity.md @@ -46,7 +46,7 @@ On 4D Server, you can filter information to be returned using the optional *sess :::note -When executed on 4D in remote or local mode, `Process activity` always returns the list of running processes (*sessionID* and *options* parameters are ignored). +Cuando se ejecuta en 4D en modo remoto o local, `Process activity` siempre devuelve la lista de procesos en ejecución (se ignoran los parámetros *sessionID* y *options*). ::: diff --git a/i18n/es/docusaurus-plugin-content-docs/version-20/REST/$compute.md b/i18n/es/docusaurus-plugin-content-docs/version-20/REST/$compute.md index 1098ddda697ea0..fccb1376df040b 100644 --- a/i18n/es/docusaurus-plugin-content-docs/version-20/REST/$compute.md +++ b/i18n/es/docusaurus-plugin-content-docs/version-20/REST/$compute.md @@ -38,8 +38,7 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri `GET /rest/Employee/salary/?$compute=$all` **Respuesta**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Si desea obtener todos los cálculos de un atributo de tipo Número, puede escri } ```` -Si desea obtener todos los cálculos de un atributo de tipo String, puede escribir: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Respuesta**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Si desea obtener un cálculo con un atributo, escriba lo siguiente: **Respuesta**: -`235000` +`335000` Si desea realizar un cálculo con un atributo Objeto, escriba lo siguiente: diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/API/CollectionClass.md b/i18n/fr/docusaurus-plugin-content-docs/current/API/CollectionClass.md index b9c66273b1b1ef..2fe0745e563ccd 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/API/CollectionClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/API/CollectionClass.md @@ -82,10 +82,10 @@ Une collection est initialisée avec les commandes [`New collection`](../command -| Paramètres | Type | | Description | -| ---------- | ------- | :-------------------------: | ----------------------------- | -| index | Integer | -> | Index de l'élément à renvoyer | -| Résultat | any | <- | L'élément à cet index | +| Paramètres | Type | | Description | +| ---------- | ------- | :-------------------------: | ------------------------------ | +| index | Integer | -> | Indice de l'élément à renvoyer | +| Résultat | any | <- | L'élément à cet indice | diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/API/FileClass.md b/i18n/fr/docusaurus-plugin-content-docs/current/API/FileClass.md index b749728656fa0e..0384f822c7a99b 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/API/FileClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/API/FileClass.md @@ -249,10 +249,10 @@ Vous souhaitez supprimer un fichier spécifique dans le dossier de la base de do
Historique -| Release | Modifications | -| ------- | ------------------------------- | -| 20 R9 | Read UUIDs in macOS executables | -| 19 | Ajout | +| Release | Modifications | +| ------- | -------------------------------------------- | +| 20 R9 | Lecture des UUIDs dans les exécutables macOS | +| 19 | Ajout |
@@ -260,19 +260,19 @@ Vous souhaitez supprimer un fichier spécifique dans le dossier de la base de do -| Paramètres | Type | | Description | -| ---------- | ------ | --------------------------- | ---------------------------- | -| Résultat | Object | <- | Application file information | +| Paramètres | Type | | Description | +| ---------- | ------ | --------------------------- | -------------------------------------------- | +| Résultat | Object | <- | Informations sur le fichier de l'application | #### Description -The `.getAppInfo()` function returns the contents of an application file information as an object. +La fonction `.getAppInfo()` renvoie le contenu des informations d'un fichier d'application sous la forme d'un objet. -The function must be used with an existing, supported file: **.plist** (all platforms), **.exe**/**.dll** (Windows), or **macOS executable**. If the file does not exist on disk or is not a supported file, the function returns an empty object (no error is generated). +La fonction doit être utilisée avec un fichier existant et pris en charge : **.plist** (toutes les plateformes), **.exe**/**.dll** (Windows), ou **exécutable macOS**. Si le fichier n'existe pas sur le disque ou n'est pas un fichier pris en charge, la fonction renvoie un objet vide (aucune erreur n'est générée). -**Returned object with a .plist file (all platforms)** +**Objet retourné avec un fichier .plist (toutes les plateformes)** Le contenu du fichier xml est analysé et les clés sont renvoyées en tant que propriétés de l'objet, en préservant leur type (texte, booléen, numérique). `.plist dict` est renvoyé sous forme d'objet JSON et `.plist array` est renvoyé sous forme de tableau JSON. @@ -282,7 +282,7 @@ Cette fonction ne prend en charge que les fichiers .plist au format xml (texte). ::: -**Returned object with a .exe or .dll file (Windows only)** +**Objet retourné avec un fichier .exe ou .dll (Windows uniquement)** Toutes les valeurs de propriétés sont de type Texte. @@ -297,11 +297,11 @@ Toutes les valeurs de propriétés sont de type Texte. | FileVersion | Text | | OriginalFilename | Text | -**Returned object with a macOS executable file (macOS only)** +**Objet retourné avec un fichier exécutable macOS (macOS uniquement)** :::note -A macOS executable file is located within a package (e.g. myApp.app/Contents/MacOS/myApp). +Un fichier exécutable macOS est situé dans un package (par exemple, myApp.app/Contents/MacOS/myApp). ::: @@ -568,11 +568,11 @@ Vous souhaitez que "ReadMe.txt" soit renommé "ReadMe_new.txt" :
Historique -| Release | Modifications | -| ------- | ------------------------------- | -| 20 R9 | Read UUIDs in macOS executables | -| 20 | Prise en charge de WinIcon | -| 19 | Ajout | +| Release | Modifications | +| ------- | -------------------------------------------- | +| 20 R9 | Lecture des UUIDs dans les exécutables macOS | +| 20 | Prise en charge de WinIcon | +| 19 | Ajout |
@@ -590,7 +590,7 @@ Vous souhaitez que "ReadMe.txt" soit renommé "ReadMe_new.txt" : The `.setAppInfo()` function writes the *info* properties as information contents of an application file. -The function must be used with an existing, supported file: **.plist** (all platforms), **.exe**/**.dll** (Windows), or **macOS executable**. If the file does not exist on disk or is not a supported file, the function does nothing (no error is generated). +La fonction doit être utilisée avec un fichier existant et pris en charge : **.plist** (toutes les plateformes), **.exe**/**.dll** (Windows), ou **exécutable macOS**. If the file does not exist on disk or is not a supported file, the function does nothing (no error is generated). ***info* parameter object with a .plist file (all platforms)** diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/Notes/updates.md b/i18n/fr/docusaurus-plugin-content-docs/current/Notes/updates.md index 196eee63f797da..e6df993bb970c5 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/Notes/updates.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/Notes/updates.md @@ -28,6 +28,7 @@ Read [**What’s new in 4D 20 R9**](https://blog.4d.com/en-whats-new-in-4d-20-R9 - New [4D AIKit component](../aikit/overview.md) enabling interaction with third-party AI APIs. - The following VP command callbacks now wait for all 4D custom functions to complete their calculations: [VP IMPORT DOCUMENT](../ViewPro/commands/vp-import-document.md), [VP IMPORT FORM BLOB](../ViewPro/commands/vp-import-from-blob.md), [VP IMPORT FROM OBJECT](../ViewPro/commands/vp-import-from-object.md), and [VP FLUSH COMMANDS](../ViewPro/commands/vp-flush-commands.md). - New [4D Netkit](https://developer.4d.com/4D-NetKit/) features to manage Google and Microsoft 365 calendars; ability to use the host web server for OAuth 2.0 authentication. +- 4D Write Pro Interface: New [integrated AI](../WritePro/writeprointerface.md#integrated-ai) to interact with **chatGTP** from your 4D Write Pro documents. - [**Fixed bug list**](https://bugs.4d.fr/fixedbugslist?version=20_R9): list of all bugs that have been fixed in 4D 20 R9. ## 4D 20 R8 diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/Project/code-overview.md b/i18n/fr/docusaurus-plugin-content-docs/current/Project/code-overview.md index 50a421c31f9323..99c6fe979d10ec 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/Project/code-overview.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/Project/code-overview.md @@ -1,26 +1,26 @@ --- id: code-overview -title: Methods and classes +title: Méthodes et classes --- -The 4D code used across your project is written in [methods](../Concepts/methods.md) and [classes](../Concepts/classes.md). +Le code 4D utilisé dans votre projet est écrit dans des [méthodes](../Concepts/methods.md) et des [classes](../Concepts/classes.md). -L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. You will usually use the included 4D [code editor](../code-editor/write-class-method.md) to work with your code. You can also use other editors such as **VS Code**, for which the [4D-Analyzer extension](https://github.com/4d/4D-Analyzer-VSCode) is available. +L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. Vous utiliserez généralement l'[éditeur intégré de code 4D](../code-editor/write-class-method.md) pour travailler avec votre code. Vous pouvez également utiliser d'autres éditeurs tels que **VS Code**, pour lesquels l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) est disponible. ## Créer des méthodes -A method in 4D is stored in a **.4dm** file located in the appropriate folder of the [`/Project/Sources/`](../Project/architecture.md#sources) folder. +Une méthode dans 4D est stockée dans un fichier **.4dm** situé dans le dossier approprié du dossier [`/Project/Sources/`](../Project/architecture.md#sources). Vous pouvez créer [plusieurs types de méthodes](../Concepts/methods.md) : -- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes Objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). -- Project methods can also be created or opened from the **File** menu or toolbar (**New/Method...** or **Open/Method...**) or using shortcuts in the [Code editor window](../code-editor/write-class-method.md#shortcuts). +- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). +- Les méthodes projet peuvent également être créées ou ouvertes à partir du menu **Fichier** ou de la barre d'outils (**Nouveau/Méthode...** ou **Ouvrir/Méthode...**) ou à l'aide de raccourcis dans la [fenêtre de l'éditeur de code](../code-editor/write-class-method.md#shortcuts). - Les triggers peuvent également être créés ou ouverts à partir de l'éditeur de Structure. - Les méthodes formulaire peuvent également être créées ou ouvertes à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md). ## Créer des classes -A user class in 4D is defined by a specific method file (**.4dm**), stored in the [`/Project/Sources/Classes/`](../Project/architecture.md#sources) folder. Le nom du fichier est le nom de la classe. +Une classe utilisateur dans 4D est définie par un fichier de méthode spécifique (**.4dm**), stocké dans le dossier [`/Project/Sources/Classes/`](../Project/architecture.md#sources). Le nom du fichier est le nom de la classe. Vous pouvez créer un fichier de classe à partir du menu ou de la barre d'outils **Fichier** (**Nouveau/Classe...**) ou dans la page **Méthodes** de la fenêtre de l'**Explorateur** . @@ -31,13 +31,13 @@ Pour plus d'informations, reportez-vous à la section [Classes](../Concepts/clas Pour supprimer une méthode ou une classe existante, vous pouvez : - sur votre disque, supprimer le fichier *.4dm* du dossier "Sources", -- in the 4D Explorer, select the method or class and click ![](../assets/en/Users/MinussNew.png) or choose **Move to Trash** from the contextual menu. +- dans l'explorateur de 4D, sélectionnez la méthode ou la classe et cliquez sur ![](../assets/en/Users/MinussNew.png) ou choisissez **Déplacer vers la corbeille** dans le menu contextuel. > Pour supprimer une méthode objet, choisissez **Supprimer la méthode objet** dans l'[éditeur de formulaires](../FormEditor/formEditor.md) (menu **Objet** ou menu contextuel). ## Importer et exporter le code -Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. These commands are found in the **Method** menu of the [Code editor](../code-editor/write-class-method.md). +Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. Ces commandes se trouvent dans le menu **Méthode** de l'[éditeur de code](../code-editor/write-class-method.md). - Lorsque vous sélectionnez la commande **Exporter la méthode...** , une boîte de dialogue standard d'enregistrement de fichier apparaît, vous permettant de choisir le nom, l'emplacement et le format du fichier d'export (voir ci-dessous). Comme pour l'impression, l'export ne tient pas compte de l'état contracté des structures de code et le code entier est exporté. - Lorsque vous sélectionnez la commande **Importer la méthode...**, une boîte de dialogue standard d'ouverture de fichier standard apparaît, vous permettant de désigner le fichier à importer. L'importation remplace le texte sélectionné dans la méthode. Pour remplacer une méthode existante par une méthode importée, il suffit de sélectionner l’ensemble du contenu de la méthode avant d’effectuer l’importation. @@ -57,8 +57,8 @@ Les autres types de méthodes n'ont pas de propriétés spécifiques. Leurs prop Pour afficher la boîte de dialogue **Propriétés de la méthode** pour une méthode projet, vous pouvez soit : -- in the [Code Editor](../code-editor/write-class-method.md), select the **Method Properties...** command in the **Method** menu, -- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Propriétés de la méthode.** dans le menu contextuel ou dans le menu d'options. +- dans l'[éditeur de code](../code-editor/write-class-method.md), sélectionnez la commande **Propriétés de la méthode...** dans le menu **Méthode**, +- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Modifier les propriétés** dans le menu contextuel ou dans le menu d'options. > Une fonction de paramétrage global vous permet de modifier une propriété pour tout ou partie des méthodes projet en une seule opération (voir [Modifier attributs globalement](#modifier-attributs-globalement)). @@ -106,7 +106,7 @@ Pour plus d'informations sur cette option, reportez-vous à [Attribut Exécuter ### Mode d’exécution -Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. It is described in the [Preemptive processes section](../Develop/preemptive.md). +Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. Elle est décrite dans la section [Process préemptifs](../Develop/preemptive.md). ### Disponibilité @@ -116,7 +116,7 @@ Les attributs de disponibilité précisent les services externes autorisés à a Cet attribut vous permet de publier la méthode courante comme service Web accessible via des requêtes SOAP. Pour plus d’informations, reportez-vous au chapitre [Publication et utilisation de Services Web](https://doc.4d.com/4Dv20/4D/20.2/Publication-and-use-of-Web-Services.200-6750103.en.html). Lorsque cette option est cochée, l’option **Publié dans WSDL** est active. -In the Explorer, project methods that are offered as a Web Service are given a specific icon. +Dans l'explorateur, les méthodes projet qui sont proposées en tant que service Web sont dotées d'une icône spécifique. **Note :** Il n'est pas possible de publier en tant que Web service une méthode dont le nom comporte des caractères non conformes à la nomenclature XML (par exemple des espaces). Si le nom de la méthode n'est pas conforme, 4D refuse l'affectation de la propriété. @@ -124,13 +124,13 @@ In the Explorer, project methods that are offered as a Web Service are given a s Cet attribut est actif uniquement si l'attribut "Web service" est coché. Il permet d’inclure la méthode courante dans le fichier WSDL de l’application 4D. Pour plus d’informations sur ce point, reportez-vous au paragraphe [Génération du WSDL](https://doc.4d.com/4Dv20/4D/20.2/Publishing-a-Web-Service-with-4D.300-6750334.en.html#502689). -In the Explorer, project methods that are offered as a Web Service and published in WSDL are given a specific icon. +Dans l'explorateur, les méthodes projet proposées en tant que service Web et publiées dans le WSDL sont dotées d'une icône spécifique. #### Balises HTML et URLs 4D (4DACTION...) -This option is used to reinforce 4D Web server security: when it is not checked, the project method cannot be executed via an HTTP request containing the special [4DACTION URL](../WebServer/httpRequests.md#4daction) used for calling 4D methods, nor the special [4DSCRIPT, 4DTEXT and 4DHTML tags](../Tags/transformation-tags.md). +Cette option permet de renforcer la sécurité du serveur Web 4D : lorsqu'elle n'est pas cochée, la méthode projet ne peut pas être exécutée via une requête HTTP contenant l'URL spéciale [4DACTION](../WebServer/httpRequests.md#4daction) utilisée pour appeler les méthodes 4D, ni les balises spéciales [4DSCRIPT, 4DTEXT et 4DHTML](../Tags/transformation-tags.md). -In the Explorer, project methods with this attribute are given a specific icon. +Dans l'explorateur, les méthodes projet ayant cet attribut sont dotées d'une icône spécifique. Pour des raisons de sécurité, cette option est désélectionnée par défaut. Vous devez désigner individuellement chaque méthode pouvant être exécutée via les URLs et les balises spéciales. @@ -138,7 +138,7 @@ Pour des raisons de sécurité, cette option est désélectionnée par défaut. Lorsqu’elle est cochée, cette option autorise l’exécution de la méthode projet par le moteur SQL de 4D. Elle est désélectionnée par défaut, ce qui signifie que, sauf autorisation explicite, les méthodes projet de 4D sont protégées et ne peuvent pas être appelées par le moteur SQL de 4D. -This property applies to all internal and external SQL queries --- executed via the ODBC driver, SQL code inserted between the [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) tags or the [QUERY BY SQL](../commands-legacy/query-by-sql.md) command. +Cette propriété s'applique à toutes les requêtes SQL internes et externes --- exécutées via le driver ODBC, le code SQL inséré entre les balises [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) ou la commande [`QUERY BY SQL`](../commands-legacy/query-by-sql.md). **Notes :** @@ -149,15 +149,15 @@ Pour plus d’informations, reportez-vous à la section [Implémentations du mot #### Serveur REST -*Cette option est obsolète. Calling code through REST calls is only supported with [ORDA data model class functions](../REST/ClassFunctions.md).* +_Cette option est obsolète. L'appel de code par le biais d'appels REST n'est possible qu'avec les [fonctions de classe du modèle de données ORDA](../REST/ClassFunctions.md).\* #### Modifier attributs globalement -Using the "Attributes for methods" dialog box, you can modify an attribute (Invisible, Offered as a Web Service, etc.) for all or part of the database project methods in a single operation. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. +La boîte de dialogue "Attributs des méthodes" permet de modifier un attribut (Invisible, Disponible via Web Services etc.) pour tout ou partie des méthodes projet de la base de données en une seule opération. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. Pour modifier globalement les attributs des méthodes : -1. On the [Methods Page](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) of the 4D Explorer, expand the options menu, then choose the **Batch setting of attributes...** command. La boîte de dialogue **Attributs des méthodes** apparaît. +1. Dans la [Page Méthodes](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) de l'explorateur 4D, développez le menu des options, puis choisissez la commande **Modifier attributs globalement...**. La boîte de dialogue **Attributs des méthodes** apparaît. 2. Dans la zone “Méthodes à modifier”, saisissez une chaîne de caractères permettant de désigner les méthodes que vous souhaitez modifier globalement. La chaîne de caractères est utilisée comme critère de recherche des noms de méthodes. @@ -166,7 +166,7 @@ Utilisez le caractère générique @ pour vous aider à définir des groupes de - pour désigner les méthodes dont le nom débute par..., saisissez @ en fin de chaîne. Par exemple : `web@` - pour désigner les méthodes dont le nom contient..., saisissez @ en milieu de chaîne. Par exemple : `web@write` -- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `web@write` +- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `@write` - Pour désigner toutes les méthodes, il suffit de taper @ dans la zone. **Notes :** diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/Project/components.md b/i18n/fr/docusaurus-plugin-content-docs/current/Project/components.md index 829e24c1b861e4..ce246df46186e3 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/Project/components.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/Project/components.md @@ -3,115 +3,115 @@ id: components title: Composants --- -A 4D component is a set of 4D code and/or 4D forms representing one or more functionalities that you can add and use in your projects. For example, the [4D SVG](https://github.com/4d/4D-SVG) component adds advanced commands and an integrated rendering engine that can be used to display SVG files. +Un composant 4D est un ensemble de code 4D et de formulaires représentant une ou plusieurs fonctionnalité(s) que vous pouvez installer et utiliser dans vos projets. Par exemple, le composant [4D SVG](https://github.com/4d/4D-SVG) ajoute des commandes avancées et un moteur de rendu intégré qui peut être utilisé pour afficher des fichiers SVG. -You can [develop](../Extensions/develop-components.md) and [build](../Desktop/building.md) your own 4D components, or download public components shared by the 4D community that can be found on GitHub. +Vous pouvez [développer](../Extensions/develop-components.md) et [construire](../Desktop/building.md) vos propres composants 4D, ou télécharger des composants publics partagés par la communauté 4D qui se trouvent sur GitHub. -When developing in 4D, the component files can be transparently stored in your computer or on a Github repository. +Lorsque vous développez dans 4D, les fichiers de composants peuvent être stockés de manière transparente sur votre ordinateur ou sur un dépôt Github. -## Interpreted and compiled components +## Composants interprétés et compilés -Components can be interpreted or [compiled](../Desktop/building.md). +Les composants peuvent être interprétés ou [compilés](../Desktop/building.md). -- A 4D project running in interpreted mode can use either interpreted or compiled components. -- A 4D project running in compiled mode cannot use interpreted components. Dans ce cas, seuls les composants compilés peuvent être utilisés. +- Un projet 4D fonctionnant en mode interprété peut utiliser des composants interprétés ou compilés. +- Un projet 4D exécuté en mode compilé ne peut pas utiliser de composants interprétés. Dans ce cas, seuls les composants compilés peuvent être utilisés. -### Package folder +### Dossier racine (package) -The package folder of a component (*MyComponent.4dbase* folder) can contain: +Le dossier racine d'un composant (dossier *MyComponent.4dbase*) peut contenir : -- for **interpreted components**: a standard [Project folder](../Project/architecture.md). The package folder name must be suffixed with **.4dbase** if you want to install it in the [**Components** folder of your project](architecture.md#components). -- for **compiled components**: - - either a "Contents" folder containing a .4DZ file, a *Resources* folder, an *Info.plist* file (recommended architecture) - - or directly a .4DZ file with other folders such as *Resources*. +- pour les **composants interprétés** : un [dossier project](../Project/architecture.md) standard. Le nom du dossier du dossier racine doit être suffixé **.4dbase** si vous voulez l'installer dans le dossier [**Components**](architecture.md#components) de votre projet. +- pour les **composants compilés** : + - soit un dossier "Contents" contenant un fichier .4DZ, un dossier *Resources*, un fichier *Info.plist* (architecture recommandée) + - soit directement un fichier .4DZ avec d'autres dossiers tels que *Resources*. :::note -The "Contents" folder architecture is recommended for components if you want to [notarize](../Desktop/building.md#about-notarization) your applications on macOS. +L'architecture de dossier "Contents" est recommandée pour les composants si vous voulez [notariser](../Desktop/building.md#about-notarization) vos applications sur macOS. ::: -## Loading components +## Chargement des composants :::note -This page describes how to work with components in the **4D** and **4D Server** environments. In other environments, components are managed differently: +Cette page décrit comment travailler avec les composants dans les environnements **4D** et **4D Server**. Dans les autres environnements, les composants sont gérés différemment : -- in [4D in remote mode](../Desktop/clientServer.md), components are loaded by the server and sent to the remote application. -- in merged applications, components are [included at the build step](../Desktop/building.md#plugins--components-page). +- dans [4D en mode distant](../Desktop/clientServer.md), les composants sont chargés par le serveur et envoyés à l'application distante. +- dans les applications fusionnées, les composants sont [inclus à l'étape de construction](../Desktop/building.md#plugins--components-page). ::: ### Vue d’ensemble -To load a component in your 4D project, you can either: +Pour charger un composant dans votre projet 4D, vous pouvez soit : -- copy the component files in the [**Components** folder of your project](architecture.md#components) (interpreted component package folders must be suffixed with ".4dbase", see above), -- or, declare the component in the **dependencies.json** file of your project; this is done automatically for local files when you [**add a dependency using the Dependency manager interface**](#adding-a-github-dependency). +- copier les fichiers des composants dans le [dossier **Components** de votre projet](architecture.md#components) (les dossiers des composants interprétés doivent être suffixés avec ".4dbase", voir ci-dessus), +- ou déclarer le composant dans le fichier **dependencies.json** de votre projet ; ceci est fait automatiquement pour les fichiers locaux lorsque vous [**ajoutez une dépendance en utilisant l'interface du Gestionnaire de dépendances**](#adding-a-github-dependency). -Components declared in the **dependencies.json** file can be stored at different locations: +Les composants déclarés dans le fichier **dependencies.json** peuvent être stockés à différents endroits : -- at the same level as your 4D project's package folder: this is the default location, -- anywhere on your machine: the component path must be declared in the **environment4d.json** file -- on a GitHub repository: the component path can be declared in the **dependencies.json** file or in the **environment4d.json** file, or in both files. +- au même niveau que le dossier racine de votre projet 4D : c'est l'emplacement par défaut, +- n'importe où sur votre machine : le chemin du composant doit être déclaré dans le fichier **environment4d.json** +- sur un dépôt GitHub : le chemin du composant peut être déclaré dans le fichier **dependencies.json** ou dans le fichier **environment4d.json**, ou dans les deux. -If the same component is installed at different locations, a [priority order](#priority) is applied. +Si le même composant est installé à différents endroits, un [ordre de priorité](#priority) est appliqué. -### dependencies.json and environment4d.json +### dependencies.json et environment4d.json #### dependencies.json -The **dependencies.json** file references all components required in your 4D project. This file must be located in the **Sources** folder of the 4D project folder, e.g.: +Le fichier **dependencies.json** référence tous les composants nécessaires à votre projet 4D. Ce fichier doit être placé dans le dossier **Sources** du dossier du projet 4D, par exemple : ``` /MyProjectRoot/Project/Sources/dependencies.json ``` -It can contain: +Il peut contenir : -- names of components [stored locally](#local-components) (default path or path defined in an **environment4d.json** file), -- names of components [stored on GitHub repositories](#components-stored-on-github) (their path can be defined in this file or in an **environment4d.json** file). +- les noms des composants [stockés localement](#local-components) (chemin par défaut ou chemin défini dans un fichier **environment4d.json**), +- les noms des composants [stockés sur des dépôts GitHub](#components-stored-on-github) (leur chemin peut être défini dans ce fichier ou dans un fichier **environment4d.json**). #### environment4d.json -The **environment4d.json** file is optional. It allows you to define **custom paths** for some or all components declared in the **dependencies.json** file. This file can be stored in your project package folder or in one of its parent folders, at any level (up to the root). +Le fichier **environment4d.json** est facultatif. Il vous permet de définir des **chemins personnalisés** pour certains ou tous les composants déclarés dans le fichier **dependencies.json**. Ce fichier peut être stocké dans le dossier racine de votre projet ou dans l'un de ses dossiers parents, à n'importe quel niveau (jusqu'à la racine). -The main benefits of this architecture are the following: +Les principaux avantages de cette architecture sont les suivants : -- you can store the **environment4d.json** file in a parent folder of your projects and decide not to commit it, allowing you to have your local component organization. -- if you want to use the same GitHub repository for several of your projects, you can reference it in the **environment4d.json** file and declare it in the **dependencies.json** file. +- vous pouvez stocker le fichier **environment4d.json** dans un dossier parent de vos projets et décider de ne pas le livrer (*commit*), ce qui vous permet d'avoir une organisation locale pour vos composants. +- si vous souhaitez utiliser le même dépôt GitHub pour plusieurs de vos projets, vous pouvez le référencer dans le fichier **environment4d.json** et le déclarer dans le fichier **dependencies.json**. -### Priority +### Priorité -Since components can be installed in different ways, a priority order is applied when the same component is referenced at several locations: +Puisque les composants peuvent être installés de différentes manières, un ordre de priorité est appliqué lorsque le même composant est référencé à plusieurs endroits : -**Higest priority** +**Priorité la plus élevée** -1. Components stored in the [**Components** folder of the project](architecture.md#components). -2. Components declared in the **dependencies.json** file (the **environment4d.json** declared path overrides the **dependencies.json** path to configure a local environment). -3. Internal User 4D components (e.g. 4D NetKit, 4D SVG...) +1. Composants stockés dans le [dossier **Components** du projet](architecture.md#components). +2. Composants déclarés dans le fichier **dependencies.json** (le chemin déclaré dans **environment4d.json** remplace le chemin **dependencies.json** pour configurer un environnement local). +3. Composants utilisateurs 4D internes (par exemple 4D NetKit, 4D SVG...) -**Lowest priority** +**Priorité la plus basse** ```mermaid flowchart TB - id1("1
Components from project's Components folder") + id1("1
Composants du dossier Components du projet") ~~~ - id2("2
Components listed in dependencies.json") - ~~~ - id2 -- environment4d.json gives path --> id4("Load component based on path declared in environment4d.json") + id2("2
Composants listés dans dependencies.json") + ~~ + id2 -- environment4d.json donne le chemin --> id4("Charger le composant basé sur le chemin déclaré dans environment4d.json") ~~~ - id3("3
User 4D components") - id2 -- environment4d.json doesn't give path --> id5("Load component next to package folder") + id3("3
Composants utilisateurs 4D internes") + id2 -- environment4d.json ne donne pas de chemin --> id5("Charger le composant à côté du dossier raciner") ~~~ - id3("3
User 4D components") + id3("3
Composants utilisateurs 4D internes") ``` -When a component cannot be loaded because of another instance of the same component located at a higher priority level, both get a specific [status](#dependency-status): the non-loaded component is given the *Overloaded* status, while the loaded component has the *Overloading* status. +Lorsqu'un composant ne peut pas être chargé à cause d'une autre instance du même composant située à un niveau de priorité plus élevé, les deux obtiennent un [statut](#dependency-status) spécifique : le composant non chargé reçoit le statut *Overloaded*, tandis que le composant chargé a le statut *Overloading*. -### Local components +### Composants locaux -You declare a local component in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant local dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -122,28 +122,28 @@ You declare a local component in the [**dependencies.json** file](#dependenciesj } ``` -... where "myComponent1" and "myComponent2" are the name of the components to be loaded. +... où "myComponent1" et "myComponent2" sont les noms des composants à charger. -By default, if "myComponent1" and "myComponent2" are not declared in an [**environment4d.json**](#environment4djson) file, 4D will look for the component's package folder (*i.e.* the project root folder of the component) at the same level as your 4D project's package folder, e.g.: +Par défaut, si "myComponent1" et "myComponent2" ne sont pas déclarés dans un fichier [**environment4d.json**](#environment4djson), 4D cherchera le dossier package du composant (c'est-à-dire le dossier racine du projet du composant) au même niveau que le dossier du package de votre projet 4D, par exemple : ``` /MyProjectRoot/ /MyProjectComponentRoot/ ``` -Thanks to this architecture, you can simply copy all your components at the same level as your projects and reference them in your **dependencies.json** files. +Grâce à cette architecture, vous pouvez simplement copier tous vos composants au même niveau que vos projets et les référencer dans vos fichiers **dependencies.json**. :::note -If you do not want to use the **dependencies.json** architecture, you can install local components by copying their files in the [**Components** folder of your project](architecture.md#components). +Si vous ne souhaitez pas utiliser l'architecture **dependencies.json**, vous pouvez installer des composants locaux en copiant leurs fichiers dans le [dossier **Components** de votre projet](architecture.md#components). ::: -#### Customizing component paths +#### Personnalisation des chemins des composants -If you want to customize the location of local components, you declare the paths for the dependencies that are not stored at the same level as the project folder in the [**environment4d.json**](#environment4djson) file. +Si vous souhaitez personnaliser l'emplacement des composants locaux, vous devez déclarer dans le fichier [**environment4d.json**](#environment4djson) les chemins des dépendances qui ne sont pas stockées au même niveau que le dossier projet. -You can use **relative** or **absolute** paths (see below). +Vous pouvez utiliser des chemins **relatifs** ou **absolus** (voir ci-dessous). Exemples : @@ -159,43 +159,43 @@ Exemples : :::note -If a component path declared in the **environment4d.json** file is not found when the project is started, the component is not loaded and gets the *Not found* [status](#dependency-status), even if a version of the component exists next to the project's package folder. +Si un chemin de composant déclaré dans le fichier **environment4d.json** n'est pas trouvé lorsque le projet est démarré, le composant n'est pas chargé et récupère le [statut](#dependency-status) *Not found*, même si une version du composant existe à côté du dossier racine du projet. ::: -#### Relative paths vs absolute paths +#### Chemins relatifs vs chemins absolus -Paths are expressed in POSIX syntax as described in [this paragraph](../Concepts/paths#posix-syntax). +Les chemins sont exprimés en syntaxe POSIX comme décrit dans [ce paragraphe](../Concepts/paths#posix-syntax). -Relative paths are relative to the [`environment4d.json`](#environment4djson) file. Absolute paths are linked to the user's machine. +Les chemins relatifs sont relatifs au fichier [`environment4d.json`](#environment4djson). Les chemins absolus sont liés à la machine de l'utilisateur. -Using relative paths is **recommended** in most cases, since they provide flexibility and portability of the components architecture, especially if the project is hosted in a source control tool. +L'utilisation de chemins relatifs est **recommandée** dans la plupart des cas, puisqu'ils fournissent flexibilité et portabilité de l'architecture des composants, surtout si le projet est hébergé dans un outil de contrôle de source. -Absolute paths should only be used for components that are specific to one machine and one user. +Les chemins absolus ne doivent être utilisés que pour les composants spécifiques à une machine et à un utilisateur. -### Components stored on GitHub +### Composants stockés sur GitHub -4D components available as GitHub releases can be referenced and automatically loaded and updated in your 4D projects. +Des composants 4D disponibles en tant que releases GitHub peuvent être référencés et automatiquement chargés et mis à jour dans vos projets 4D. :::note -Regarding components stored on GitHub, both [**dependencies.json**](#dependenciesjson) and [**environment4d.json**](#environment4djson) files support the same contents. +En ce qui concerne les composants stockés sur GitHub, les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson) prennent en charge le même contenu. ::: -#### Configuring the GitHub repository +#### Configuration du dépôt GitHub -To be able to directly reference and use a 4D component stored on GitHub, you need to configure the GitHub component's repository: +Pour pouvoir référencer et utiliser directement un composant 4D stocké sur GitHub, vous devez configurer le dépôt du composant GitHub : -- Compress the component files in ZIP format. -- Name this archive with the same name as the GitHub repository. -- Integrate the archive into a [GitHub release](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) of the repository. +- Compressez les fichiers des composants au format ZIP. +- Nommez cette archive avec le même nom que le dépôt GitHub. +- Intégrez l'archive dans une [release GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) du dépôt. -These steps can easily be automated, with 4D code or using GitHub Actions, for example. +Ces étapes peuvent être facilement automatisées, avec du code 4D ou en utilisant des actions GitHub, par exemple. -#### Declaring paths +#### Déclaration des chemins -You declare a component stored on GitHub in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant stocké sur GitHub dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -208,7 +208,7 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -... where "myGitHubComponent1" is referenced and declared for the project, although "myGitHubComponent2" is only referenced. You need to declare it in the [**environment4d.json**](#environment4djson) file: +... où "myGitHubComponent1" est référencé et déclaré pour le projet, tandis que "myGitHubComponent2" est seulement référencé. Vous devez le déclarer dans le fichier [**environment4d.json**](#environment4djson) : ```json { @@ -220,19 +220,19 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -"myGitHubComponent2" can be used by several projects. +"myGitHubComponent2" peut être utilisé par plusieurs projets. -#### Tags and versions +#### Tags et versions -When a release is created in GitHub, it is associated to a **tag** and a **version**. The Dependency manager uses these information to handle automatic availability of components. +Lorsqu'une release est créée dans GitHub, elle est associée à un **tag** et à une **version**. Le gestionnaire de dépendances utilise ces informations pour gérer la disponibilité automatique des composants. :::note -If you select the [**Follow 4D Version**](#defining-a-github-dependency-version-range) dependency rule, you need to use a [specific naming convention for the tags](#naming-conventions-for-4d-version-tags). +Si vous sélectionnez la règle de dépendance [**Suivre la version 4D**](#defining-a-github-dependency-version-range), vous devez utiliser une [convention de nommage spécifique pour les tags](#naming-conventions-for-4d-version-tags). ::: -- **Tags** are texts that uniquely reference a release. In the [**dependencies.json** file](#dependenciesjson) and [**environment4d.json**](#environment4djson) files, you can indicate the release tag you want to use in your project. For example : +- Les **Tags** sont des textes qui référencent de manière unique une release. Dans les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson), vous pouvez indiquer le release tag que vous souhaitez utiliser dans votre projet. Par exemple : ```json { @@ -245,7 +245,7 @@ If you select the [**Follow 4D Version**](#defining-a-github-dependency-version- } ``` -- A release is also identified by a **version**. The versioning system used is based on the [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/) concept, which is the most commonly used. Each version number is identified as follows: `majorNumber.minorNumber.pathNumber`. In the same way as for tags, you can indicate the version of the component you wish to use in your project, as in this example: +- Une release est également identifiée par une **version**. Le système de versionnement utilisé est basé sur le concept de [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/), qui est le plus couramment utilisé. Chaque numéro de version est identifié comme suit : `majorNumber.minorNumber.pathNumber`. De la même manière que pour les tags, vous pouvez indiquer la version du composant que vous souhaitez utiliser dans votre projet, comme dans cet exemple : ```json { @@ -258,149 +258,149 @@ If you select the [**Follow 4D Version**](#defining-a-github-dependency-version- } ``` -A range is defined by two semantic versions, a min and a max, with operators '\< | > | >= | <= | ='. The `*` can be used as a placeholder for all versions. ~ and ^ prefixes define versions starting at a number, and up to respectively the next major and minor version. +Un intervalle est défini par deux versions sémantiques, un minimum et un maximum, avec les opérateurs "\< | > | >= | <= | =". Le `*` peut être utilisé comme substitut pour toutes les versions. Les préfixes ~ et ^ définissent les versions à partir d'un numéro, et jusqu'à respectivement la version majeure et mineure suivante. -Here are a few examples: +Voici quelques exemples : -- "latest": the version having the “latest” badge in GitHub releases. -- "\*": the latest version released. -- "1.\*": all version of major version 1. -- "1.2.\*": all patches of minor version 1.2. -- ">=1.2.3": the latest version, starting with the 1.2.3 version. -- ">1.2.3": the latest version, starting with the version just after the 1.2.3. -- "^1.2.3": the latest version 1, starting with the 1.2.3 version and strictly lower than version 2. -- "~1.2.3": the latest version 1.2, starting with the 1.2.3 version and strictly lower than version 1.3. -- "<=1.2.3": the latest version until the 1.2.3 one. -- "1.0.0 – 1.2.3" or ">=1.0.0 <=1.2.3": version between 1.0.0 and 1.2.3. -- "`<1.2.3 || >=2`": version that is not between 1.2.3 and 2.0.0. +- "latest" : la version ayant le badge "latest" dans les releases GitHub. +- "\*" : la dernière version publiée. +- "1.\*" : toutes les versions de la version majeure 1. +- "1.2.\*" : tous les correctifs de la version mineure 1.2. +- ">=1.2.3" : la dernière version, à partir de la version 1.2.3. +- ">1.2.3" : la dernière version, en commençant par la version juste après la 1.2.3. +- "^1.2.3" : la dernière version 1, à partir de la version 1.2.3 et strictement inférieure à la version 2. +- "~1.2.3" : la dernière version 1.2, à partir de la version 1.2.3 et strictement inférieure à la version 1.3. +- "<=1.2.3" : la dernière version jusqu'à la 1.2.3. +- "1.0.0 - 1.2.3" ou ">=1.0.0 <=1.2.3" : version comprise entre 1.0.0 et 1.2.3. +- "`<1.2.3 || >=2`" : version qui n'est pas comprise entre 1.2.3 et 2.0.0. -If you do not specify a tag or a version, 4D automatically retrieves the "latest" version. +Si vous ne spécifiez pas de tag ou de version, 4D récupère automatiquement la version "latest". -The Dependency manager checks periodically if component updates are available on Github. If a new version is available for a component, an update indicator is then displayed for the component in the dependency list, [depending on your settings](#defining-a-github-dependency-version-range). +Le Gestionnaire de dépendances vérifie périodiquement si des mises à jour de composants sont disponibles sur Github. Si une nouvelle version est disponible pour un composant, un indicateur de mise à jour est alors affiché pour le composant dans la liste des dépendances, [en fonction de vos paramètres](#defining-a-github-dependency-version-range). -#### Naming conventions for 4D version tags +#### Conventions de nommage pour les tags de version 4D -If you want to use the [**Follow 4D Version**](#defining-a-github-dependency-version-range) dependency rule, the tags for component releases on the Github repository must comply with specific conventions. +Si vous souhaitez utiliser la règle de dépendance [**Suivre la version 4D**](#defining-a-github-dependency-version-range), les tags des releases des composants sur le dépôt Github doivent respecter des conventions spécifiques. -- **LTS versions**: `x.y.p` pattern, where `x.y` corresponds to the main 4D version to follow and `p` (optional) can be used for patch versions or additional updates. When a project specifies that it follows the 4D version for *x.y* LTS version, the Dependency Manager will resolve it as "the latest version x.\*" if available or "version below x". If no such version exists, the user will be notified. For example, "20.4" will be resolved by the Dependency manager as "the latest component version 20.\* or version below 20". +- **Versions LTS** : Modèle `x.y.p`, où `x.y` correspond à la version principale de 4D à suivre et `p` (facultatif) peut être utilisé pour les versions correctives ou les mises à jour supplémentaires. Lorsqu'un projet spécifie qu'il suit la version 4D pour la version LTS *x.y*, le Gestionnaire de dépendances le résoudra comme "la dernière version x.\*" si elle est disponible ou "une version inférieure à x". Si une telle version n'existe pas, l'utilisateur en sera informé. Par exemple, "20.4" sera résolu par le Gestionnaire de dépendances comme "la dernière version du composant 20.\* ou une version inférieure à 20". -- **R-Release versions**: `xRy.p` pattern, where `x` and `y` correspond to the main 4D R-release version to follow and `p` (optional) can be used for patch versions or additional updates. When a project specifies that it follows the 4D version for *xRy* version, the Dependency Manager will resolve it to the "latest version below xR(y+1)" if available. If no such version exists, the user will be notified. For example, "20R9" will be resolved by the Dependency manager as "the latest component version below 20R10". +- **Versions R-Release** : Modèle `xRy.p`, où `x` et `y` correspondent à la version principale de 4D R à suivre et `p` (facultatif) peut être utilisé pour les versions correctives ou les mises à jour supplémentaires. Lorsqu'un projet spécifie qu'il suit la version 4D pour la version *xRy*, le Gestionnaire de dépendances le résoudra à la "dernière version inférieure à xR(y+1)" si elle est disponible. Si une telle version n'existe pas, l'utilisateur en sera informé. Par exemple, "20R9" sera résolu par le gestionnaire de dépendances comme "la dernière version du composant inférieure à 20R10". :::note -The component developer can define a minimum 4D version in the component's [`info.plist`](../Extensions/develop-components.md#infoplist) file. +Le développeur du composant peut définir une version 4D minimale dans le fichier [`info.plist`](../Extensions/develop-components.md#infoplist) du composant. ::: -#### Private repositories +#### Dépôts privés -If you want to integrate a component located in a private repository, you need to tell 4D to use a connection token to access it. +Si vous souhaitez intégrer un composant situé dans un référentiel privé, vous devez indiquer à 4D d'utiliser un token (*jeton*) de connexion pour y accéder. -To do this, in your GitHub account, create a **classic** token with access rights to **repo**. +Pour cela, dans votre compte GitHub, créez un token **classic** avec les droits d'accès au **dépôt**. :::note -For more information, please refer to the [GitHub token interface](https://github.com/settings/tokens). +Pour plus d'informations, veuillez vous référer à [GitHub token interface](https://github.com/settings/tokens). ::: -You then need to [provide your connection token](#providing-your-github-access-token) to the Dependency manager. +Vous devez ensuite [fournir votre token de connexion](#providing-your-github-access-token) au Gestionnaire de dépendances. -#### Local cache for dependencies +#### Cache local pour les dépendances -Referenced GitHub components are downloaded in a local cache folder then loaded in your environment. The local cache folder is stored at the following location: +Les composants GitHub référencés sont téléchargés dans un dossier de cache local puis chargés dans votre environnement. Le dossier de cache local est stocké à l'emplacement suivant : -- on macOs: `$HOME/Library/Caches//Dependencies` -- on Windows: `C:\Users\\AppData\Local\\Dependencies` +- sous macOs : `$HOME/Library/Caches//Dependencies` +- sous Windows : `C:\Users\\AppData\Local\\Dependencies` -...where `` can be "4D", "4D Server", or "tool4D". +...où `` peut être "4D", "4D Server" ou "tool4D". ### dependency-lock.json -A `dependency-lock.json` file is created in the [`userPreferences` folder](architecture.md#userpreferencesusername) of your project. +Un fichier `dependency-lock.json` est créé dans le dossier [`userPreferences`](architecture.md#userpreferencesusername) de votre projet. -This file logs information such as the state of dependencies, paths, urls, loading errors, as well as other information. It could be useful for component loading management or troubleshooting. +Ce fichier enregistre des informations telles que le statut des dépendances, les chemins d'accès, les Url, les erreurs de chargement, ainsi que d'autres informations. Il peut être utile pour la gestion du chargement de composants ou le dépannage. -## Monitoring Project Dependencies +## Suivi des dépendances du projet -In an opened project, you can add, remove, update, and get information about dependencies and their current loading status in the **Dependencies** panel. +Dans un projet ouvert, vous pouvez ajouter, supprimer, mettre à jour et obtenir des informations sur les dépendances et leur statut courant de chargement dans la fenêtre **Dépendances**. -To display the Dependencies panel: +Pour afficher la fenêtre Dépendances : -- with 4D, select the **Design/Project Dependencies** menu item (Development environment),
+- avec 4D, sélectionnez la ligne de menu **Développement/Dépendances du projet** (environnement de développement),
![dependency-menu](../assets/en/Project/dependency-menu.png) -- with 4D Server, select the **Window/Project Dependencies** menu item.
- ![dependency-menu-server](../assets/en/Project/dependency-menu-server.png) +- avec 4D Server, sélectionnez la ligne de menu **Fenêtre/Dépendances du projet**.
+ ![menu-dépendances-serveur](../assets/en/Project/dependency-menu-server.png) -The Dependencies panel is then displayed. Dependencies are sorted by name in alphabetical order: +La fenêtre Dépendances s'affiche alors. Les dépendances sont classées par nom par ordre alphabétique : ![dependency](../assets/en/Project/dependency.png) -The Dependencies panel interface allows you to manage dependencies (on 4D single-user and 4D Server). +L'interface de la fenêtre Dépendances vous permet de gérer les dépendances (sur 4D monoposte et 4D Server). -### Filtering dependencies +### Filtrer les dépendances -By default, all dependencies identified by the Dependency manager are listed, whatever their [status](#dependency-status). You can filter the displayed dependencies according to their status by selecting the appropriate tab at the top of the Dependencies panel: +Par défaut, toutes les dépendances identifiées par le Gestionnaire de dépendances sont listées, quel que soit leur [statut](#dependency-status). Vous pouvez filtrer les dépendances affichées en fonction de leur statut en sélectionnant l'onglet approprié en haut de la fenêtre : ![dependency-tabs](../assets/en/Project/dependency-tabs.png) -- **Active**: Dependencies that are loaded and can be used in the project. It includes *overloading* dependencies, which are actually loaded. *Overloaded* dependencies are listed in the **Conflicts** panel, along with all conflicting dependencies. -- **Inactive**: Dependencies that are not loaded in the project and are not available. There are many possible reasons for this status: missing files, version incompatibility... -- **Conflict**: Dependencies that are loaded but that overloads at least one other dependency at lower [priority level](#priority). Overloaded dependencies are also displayed so that you can check the origin of the conflict and take appropriate actions. +- **Actifs** : Dépendances chargées et utilisables dans le projet. Il comprend des dépendances *overloading*, qui sont effectivement chargées. Les dépendances *overloaded* sont listées dans l'onglet **Conflits**, ainsi que toutes les dépendances conflictuelles. +- **Inactifs** : Dépendances qui ne sont pas chargées dans le projet et qui ne sont pas disponibles. Diverses raisons peuvent expliquer ce statut : fichiers manquants, incompatibilité de version... +- **Conflit** : Dépendances qui sont chargées mais qui surchargent au moins une autre dépendance à un [niveau de priorité](#priority) inférieur. Les dépendances surchargées sont également affichées afin que vous puissiez vérifier l'origine du conflit et prendre les mesures appropriées. -### Dependency status +### Statut des dépendances -Dependencies requiring the developer's attention are indicated by a **status label** at the right side of the line and a specific background color: +Les dépendances nécessitant l'attention du développeur sont signalées par une **étiquette de statut** à droite de la ligne et une couleur de fond spécifique : ![dependency-status](../assets/en/Project/dependency-conflict2.png) -The following status labels are available: +Les étiquettes de statut suivantes sont disponibles : -- **Overloaded**: The dependency is not loaded because it is overloaded by another dependency with the same name at a higher [priority level](#priority). -- **Overloading**: The dependency is loaded and is overloading one or more other dependencies with the same name at a lower [priority level](#priority). -- **Not found**: The dependency is declared in the dependencies.json file but is not found. -- **Inactive**: The dependency is not loaded because it is not compatible with the project (e.g. the component is not compiled for the current platform). -- **Duplicated**: The dependency is not loaded because another dependency with the same name exists at the same location (and is loaded). -- **Available after restart**: The dependency reference has just been added or updated [using the interface](#monitoring-project-dependencies), it will be loaded once the application restarts. -- **Unloaded after restart**: The dependency reference has just been removed [using the interface](#removing-a-dependency), it will be unloaded once the application restarts. -- **Update available \**: A new version of the GitHub dependency matching your [component version configuration](#defining-a-github-dependency-version-range) has been detected. -- **Refreshed after restart**: The [component version configuration](#defining-a-github-dependency-version-range) of the GitHub dependency has been modified, it will be adjusted the next startup. -- **Recent update**: A new version of the GitHub dependency has been loaded at startup. +- **Overloaded** : La dépendance n'est pas chargée car elle est surchargée par une autre dépendance portant le même nom et ayant un [niveau de priorité](#priority) plus élevé. +- **Overloading** : La dépendance est chargée et surcharge une ou plusieurs autres dépendances avec le même nom à un [niveau de priorité](#priority) inférieur. +- **Non trouvé** : La dépendance est déclarée dans le fichier dependencies.json mais n'est pas trouvée. +- **Inactif** : La dépendance n'est pas chargée car elle n'est pas compatible avec le projet (par exemple, le composant n'est pas compilé pour la plate-forme actuelle). +- **Dupliqué** : La dépendance n'est pas chargée car une autre dépendance portant le même nom existe au même endroit (et est chargée). +- **Disponible après redémarrage** : La référence de la dépendance vient d'être ajoutée ou mise à jour [à l'aide de l'interface](#monitoring-project-dependencies), elle sera chargée une fois que l'application aura redémarré. +- **Déchargé après redémarrage** : La référence à la dépendance vient d'être supprimée [en utilisant l'interface](#removing-a-dependency), elle sera déchargée une fois que l'application aura redémarré. +- **Mise à jour disponible \** : Une nouvelle version de la dépendance GitHub correspondant à votre [configuration de version du composant](#defining-a-github-dependency-version-range) a été détectée. +- **Actualisé après redémarrage** : La [configuration de version](#defining-a-github-dependency-version-range) de la dépendance GitHub a été modifiée, elle sera ajustée au prochain démarrage. +- **Mise à jour récente** : Une nouvelle version de la dépendance GitHub a été chargée au démarrage. -A tooltip is displayed when you hover over the dependency line, provding additional information about the status: +Une infobulle s'affiche lorsque vous survolez la ligne de dépendance, fournissant des informations supplémentaires sur le statut : ![dependency-tips](../assets/en/Project/dependency-tip1.png) -### Dependency origin +### Origine de la dépendance -The Dependencies panel lists all project dependencies, whatever their origin, i.e. wherever they come from. The dependency origin is provided by the tag under its name: +Le panneau Dépendances liste toutes les dépendances du projet, quelle que soit leur origine, c'est-à-dire d'où qu'elles viennent. L'origine de la dépendance est fournie par l'étiquette sous son nom : ![dependency-origin](../assets/en/Project/dependency-origin.png) -The following origins are possible: +Les options suivantes sont disponibles : -| Origin tag | Description | +| Étiquette d'origine | Description | | --------------------------------- | ------------------------------------------------------------------------------ | -| 4D Component | Built-in 4D component, stored in the `Components` folder of the 4D application | -| dependencies.json | Component declared in the [`dependencies.json`](#dependenciesjson) file | -| Environment | Component declared in the [`environnement4d.json`](#environment4djson) file | -| Project Component | Component located in the [`Components`](architecture.md#components) folder | +| Composant 4D | Composant 4D intégré, stocké dans le dossier `Components` de l'application 4D | +| dependencies.json | Composant déclaré dans le fichier [`dependencies.json`](#dependenciesjson) | +| Environnement | Composant déclaré dans le fichier [`environnement4d.json`](#environment4djson) | +| Composant du projet | Composant situé dans le dossier [`Components`](architecture.md#components) | -**Right-click** in a dependency line and select **Show on disk** to reveal the location of a dependency: +**Cliquez avec le bouton droit de la souris** dans une ligne de dépendance et sélectionnez **Afficher sur le disque** pour révéler l'emplacement d'une dépendance : ![dependency-show](../assets/en/Project/dependency-show.png) :::note -This item is not displayed if the dependency is inactive because its files are not found. +Cet élément n'est pas affiché si la dépendance est inactive parce que ses fichiers sont introuvables. ::: -Component icon and location logo provide additional information: +L'icône du composant et le logo de l'emplacement fournissent des informations supplémentaires : -- The component logo indicates if it is provided by 4D or a third-party developer. -- Local components can be differentiated from GitHub components by a small icon. +- Le logo du composant indique s'il est fourni par 4D ou par un développeur tiers. +- Les composants locaux peuvent être différenciés des composants GitHub par une petite icône. ![dependency-origin](../assets/en/Project/dependency-github.png) diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/REST/$attributes.md b/i18n/fr/docusaurus-plugin-content-docs/current/REST/$attributes.md index d5210c3aa0ea91..68e3e192e83f70 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/REST/$attributes.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/REST/$attributes.md @@ -3,11 +3,11 @@ id: attributes title: $attributes --- -Allows selecting the attribute(s) to get from the dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, or `Employee?$attributes=employer.name`). +Permet de sélectionner le ou les attribut(s) à obtenir de la dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, ou `Employee?$attributes=employer.name`). ## Description -If you have relation attributes in a dataclass, use `$attributes` to define the path of attributes whose values you want to get for the related entity or entities. +Lorsque vous avez des attributs relationnels dans une dataclass, utilisez `$attributes` pour définir le chemin des attributs dont vous souhaitez obtenir les valeurs pour l'entité ou les entités associée(s). Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) ou à une entity selection (par exemple, People/$entityset/0AF4679A5C394746BFEB68D2162A19FF). @@ -22,8 +22,8 @@ Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) - `$attributes=relatedEntities.*` : toutes les propriétés des entités liées sont retournées - `$attributes=relatedEntities.attributePath1, relatedEntity.attributePath2, ...` : seuls ces attributs des entités liées sont retournés. -- If `$attributes` is specified for **storage** attributes: - - `$attributes=attribute1, attribute2, ...`: only those attributes of the entities are returned. +- Si `$attributes` est spécifié pour les attributs **storage** : + - `$attributes=attribute1, attribute2, ...` : seuls les attributs des entités sont renvoyés. ## Exemple avec plusieurs entités liées diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/REST/$compute.md b/i18n/fr/docusaurus-plugin-content-docs/current/REST/$compute.md index 3e5da3f941b00f..d7c4fae7dcff95 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/REST/$compute.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/REST/$compute.md @@ -36,7 +36,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, **Réponse** : -``` +```js { "salary": { "count": 4, @@ -54,7 +54,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Chaîne, vou **Réponse** : -``` +```js { "salary": { "count": 4, @@ -70,7 +70,7 @@ Si vous souhaitez obtenir un calcul avec un attribut, vous pouvez écrire ce qui **Réponse** : -`235000` +`335000` Si vous souhaitez effectuer un calcul avec un attribut Objet, vous pouvez saisir ce qui suit : diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md b/i18n/fr/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md index 5bb8d35e484ec0..f77757f2750316 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Un développeur 4D peut facilement implémenter ces palettes dans leur applicati La documentation principale de l'[interface 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se trouve dans le *4D - Mode Développement*. -Vous trouverez ci-dessous la documentation de configuration de l'Assistant de table. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Assistant de table @@ -294,4 +297,114 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### Voir également -[4D Write Pro - Table Wizard (vidéo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (vidéo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Historique + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/current/code-editor/write-class-method.md b/i18n/fr/docusaurus-plugin-content-docs/current/code-editor/write-class-method.md index 96d46eb142d084..3513373fd38a40 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/current/code-editor/write-class-method.md +++ b/i18n/fr/docusaurus-plugin-content-docs/current/code-editor/write-class-method.md @@ -15,7 +15,7 @@ L'éditeur de code 4D fournit un contrôle de base des erreurs de syntaxe. Un co :::note -If you are used to coding with **VS Code**, you can also use this editor with 4D code after installing the [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) extension. +Si vous avez l'habitude de coder avec **VS Code**, vous pouvez également utiliser cet éditeur avec le Langage 4D après avoir installé l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode). ::: @@ -33,7 +33,7 @@ Chaque fenêtre de l'éditeur de code dispose d'une barre d'outils qui permet un | **Déployer tout / Contracter tout** | ![expand-collapse-button](../assets/en/code-editor/expand-collapse-all.png) | Ces boutons permettent de déployer ou de contracter toutes les structures de flux de contrôle du code. | | **Informations sur la méthode** | ![method-information-icon](../assets/en/code-editor/method-information.png) | Affiche la boîte de dialogue [Propriétés de la méthode](../Project/code-overview.md#project-method-properties) (méthodes de projet uniquement). | | **Dernières valeurs du presse-papiers** | ![last-clipboard-values-icon](../assets/en/code-editor/last-clipboard-values.png) | Affiche les dernières valeurs stockées dans le presse-papiers. | -| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. You can [use these clipboards](#clipboards) by clicking on them directly or by using keyboard shortcuts. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | +| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. Vous pouvez [utiliser ces presse-papiers](#clipboards) en cliquant directement dessus ou en utilisant des raccourcis clavier. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | | **Menu déroulant de navigation** | ![code-navigation-icons](../assets/en/code-editor/tags.png) | Vous permet de naviguer à l'intérieur des méthodes et des classes avec du contenu étiqueté automatiquement ou des marqueurs déclarés manuellement. Voir ci-dessous | ### Zone d'édition @@ -368,7 +368,7 @@ La liste est par ordre alphabétique. Choisissez la valeur en double-cliquant de Par défaut, vous pouvez également insérer une valeur suggérée en appuyant sur l'un des délimiteurs suivants `( ; : = < [ {` après avoir sélectionné une valeur : la valeur insérée est ensuite suivie du délimiteur, prête pour la saisie des données. -![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** key --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) +![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** touche --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) > Vous pouvez désactiver l'utilisation de délimiteurs pour insérer des valeurs suggérées dans les **Préférences** > **Méthodes** > **Options**. diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-19/REST/$compute.md b/i18n/fr/docusaurus-plugin-content-docs/version-19/REST/$compute.md index d6da37af49a22c..d63061d2e5b07d 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-19/REST/$compute.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-19/REST/$compute.md @@ -38,8 +38,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, `GET /rest/Employee/salary/?$compute=$all` **Réponse** : - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, } ```` -Si vous souhaitez obtenir tous les calculs pour un attribut de type Chaîne, vous pouvez écrire : +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Réponse** : +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Si vous souhaitez obtenir un calcul avec un attribut, vous pouvez écrire ce qui **Réponse** : -`235000` +`335000` Si vous souhaitez effectuer un calcul avec un attribut Objet, vous pouvez saisir ce qui suit : diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/API/CollectionClass.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/API/CollectionClass.md index b9c66273b1b1ef..2fe0745e563ccd 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/API/CollectionClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/API/CollectionClass.md @@ -82,10 +82,10 @@ Une collection est initialisée avec les commandes [`New collection`](../command -| Paramètres | Type | | Description | -| ---------- | ------- | :-------------------------: | ----------------------------- | -| index | Integer | -> | Index de l'élément à renvoyer | -| Résultat | any | <- | L'élément à cet index | +| Paramètres | Type | | Description | +| ---------- | ------- | :-------------------------: | ------------------------------ | +| index | Integer | -> | Indice de l'élément à renvoyer | +| Résultat | any | <- | L'élément à cet indice | diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/code-overview.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/code-overview.md index 50a421c31f9323..99c6fe979d10ec 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/code-overview.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/code-overview.md @@ -1,26 +1,26 @@ --- id: code-overview -title: Methods and classes +title: Méthodes et classes --- -The 4D code used across your project is written in [methods](../Concepts/methods.md) and [classes](../Concepts/classes.md). +Le code 4D utilisé dans votre projet est écrit dans des [méthodes](../Concepts/methods.md) et des [classes](../Concepts/classes.md). -L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. You will usually use the included 4D [code editor](../code-editor/write-class-method.md) to work with your code. You can also use other editors such as **VS Code**, for which the [4D-Analyzer extension](https://github.com/4d/4D-Analyzer-VSCode) is available. +L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. Vous utiliserez généralement l'[éditeur intégré de code 4D](../code-editor/write-class-method.md) pour travailler avec votre code. Vous pouvez également utiliser d'autres éditeurs tels que **VS Code**, pour lesquels l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) est disponible. ## Créer des méthodes -A method in 4D is stored in a **.4dm** file located in the appropriate folder of the [`/Project/Sources/`](../Project/architecture.md#sources) folder. +Une méthode dans 4D est stockée dans un fichier **.4dm** situé dans le dossier approprié du dossier [`/Project/Sources/`](../Project/architecture.md#sources). Vous pouvez créer [plusieurs types de méthodes](../Concepts/methods.md) : -- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes Objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). -- Project methods can also be created or opened from the **File** menu or toolbar (**New/Method...** or **Open/Method...**) or using shortcuts in the [Code editor window](../code-editor/write-class-method.md#shortcuts). +- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). +- Les méthodes projet peuvent également être créées ou ouvertes à partir du menu **Fichier** ou de la barre d'outils (**Nouveau/Méthode...** ou **Ouvrir/Méthode...**) ou à l'aide de raccourcis dans la [fenêtre de l'éditeur de code](../code-editor/write-class-method.md#shortcuts). - Les triggers peuvent également être créés ou ouverts à partir de l'éditeur de Structure. - Les méthodes formulaire peuvent également être créées ou ouvertes à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md). ## Créer des classes -A user class in 4D is defined by a specific method file (**.4dm**), stored in the [`/Project/Sources/Classes/`](../Project/architecture.md#sources) folder. Le nom du fichier est le nom de la classe. +Une classe utilisateur dans 4D est définie par un fichier de méthode spécifique (**.4dm**), stocké dans le dossier [`/Project/Sources/Classes/`](../Project/architecture.md#sources). Le nom du fichier est le nom de la classe. Vous pouvez créer un fichier de classe à partir du menu ou de la barre d'outils **Fichier** (**Nouveau/Classe...**) ou dans la page **Méthodes** de la fenêtre de l'**Explorateur** . @@ -31,13 +31,13 @@ Pour plus d'informations, reportez-vous à la section [Classes](../Concepts/clas Pour supprimer une méthode ou une classe existante, vous pouvez : - sur votre disque, supprimer le fichier *.4dm* du dossier "Sources", -- in the 4D Explorer, select the method or class and click ![](../assets/en/Users/MinussNew.png) or choose **Move to Trash** from the contextual menu. +- dans l'explorateur de 4D, sélectionnez la méthode ou la classe et cliquez sur ![](../assets/en/Users/MinussNew.png) ou choisissez **Déplacer vers la corbeille** dans le menu contextuel. > Pour supprimer une méthode objet, choisissez **Supprimer la méthode objet** dans l'[éditeur de formulaires](../FormEditor/formEditor.md) (menu **Objet** ou menu contextuel). ## Importer et exporter le code -Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. These commands are found in the **Method** menu of the [Code editor](../code-editor/write-class-method.md). +Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. Ces commandes se trouvent dans le menu **Méthode** de l'[éditeur de code](../code-editor/write-class-method.md). - Lorsque vous sélectionnez la commande **Exporter la méthode...** , une boîte de dialogue standard d'enregistrement de fichier apparaît, vous permettant de choisir le nom, l'emplacement et le format du fichier d'export (voir ci-dessous). Comme pour l'impression, l'export ne tient pas compte de l'état contracté des structures de code et le code entier est exporté. - Lorsque vous sélectionnez la commande **Importer la méthode...**, une boîte de dialogue standard d'ouverture de fichier standard apparaît, vous permettant de désigner le fichier à importer. L'importation remplace le texte sélectionné dans la méthode. Pour remplacer une méthode existante par une méthode importée, il suffit de sélectionner l’ensemble du contenu de la méthode avant d’effectuer l’importation. @@ -57,8 +57,8 @@ Les autres types de méthodes n'ont pas de propriétés spécifiques. Leurs prop Pour afficher la boîte de dialogue **Propriétés de la méthode** pour une méthode projet, vous pouvez soit : -- in the [Code Editor](../code-editor/write-class-method.md), select the **Method Properties...** command in the **Method** menu, -- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Propriétés de la méthode.** dans le menu contextuel ou dans le menu d'options. +- dans l'[éditeur de code](../code-editor/write-class-method.md), sélectionnez la commande **Propriétés de la méthode...** dans le menu **Méthode**, +- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Modifier les propriétés** dans le menu contextuel ou dans le menu d'options. > Une fonction de paramétrage global vous permet de modifier une propriété pour tout ou partie des méthodes projet en une seule opération (voir [Modifier attributs globalement](#modifier-attributs-globalement)). @@ -106,7 +106,7 @@ Pour plus d'informations sur cette option, reportez-vous à [Attribut Exécuter ### Mode d’exécution -Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. It is described in the [Preemptive processes section](../Develop/preemptive.md). +Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. Elle est décrite dans la section [Process préemptifs](../Develop/preemptive.md). ### Disponibilité @@ -116,7 +116,7 @@ Les attributs de disponibilité précisent les services externes autorisés à a Cet attribut vous permet de publier la méthode courante comme service Web accessible via des requêtes SOAP. Pour plus d’informations, reportez-vous au chapitre [Publication et utilisation de Services Web](https://doc.4d.com/4Dv20/4D/20.2/Publication-and-use-of-Web-Services.200-6750103.en.html). Lorsque cette option est cochée, l’option **Publié dans WSDL** est active. -In the Explorer, project methods that are offered as a Web Service are given a specific icon. +Dans l'explorateur, les méthodes projet qui sont proposées en tant que service Web sont dotées d'une icône spécifique. **Note :** Il n'est pas possible de publier en tant que Web service une méthode dont le nom comporte des caractères non conformes à la nomenclature XML (par exemple des espaces). Si le nom de la méthode n'est pas conforme, 4D refuse l'affectation de la propriété. @@ -124,13 +124,13 @@ In the Explorer, project methods that are offered as a Web Service are given a s Cet attribut est actif uniquement si l'attribut "Web service" est coché. Il permet d’inclure la méthode courante dans le fichier WSDL de l’application 4D. Pour plus d’informations sur ce point, reportez-vous au paragraphe [Génération du WSDL](https://doc.4d.com/4Dv20/4D/20.2/Publishing-a-Web-Service-with-4D.300-6750334.en.html#502689). -In the Explorer, project methods that are offered as a Web Service and published in WSDL are given a specific icon. +Dans l'explorateur, les méthodes projet proposées en tant que service Web et publiées dans le WSDL sont dotées d'une icône spécifique. #### Balises HTML et URLs 4D (4DACTION...) -This option is used to reinforce 4D Web server security: when it is not checked, the project method cannot be executed via an HTTP request containing the special [4DACTION URL](../WebServer/httpRequests.md#4daction) used for calling 4D methods, nor the special [4DSCRIPT, 4DTEXT and 4DHTML tags](../Tags/transformation-tags.md). +Cette option permet de renforcer la sécurité du serveur Web 4D : lorsqu'elle n'est pas cochée, la méthode projet ne peut pas être exécutée via une requête HTTP contenant l'URL spéciale [4DACTION](../WebServer/httpRequests.md#4daction) utilisée pour appeler les méthodes 4D, ni les balises spéciales [4DSCRIPT, 4DTEXT et 4DHTML](../Tags/transformation-tags.md). -In the Explorer, project methods with this attribute are given a specific icon. +Dans l'explorateur, les méthodes projet ayant cet attribut sont dotées d'une icône spécifique. Pour des raisons de sécurité, cette option est désélectionnée par défaut. Vous devez désigner individuellement chaque méthode pouvant être exécutée via les URLs et les balises spéciales. @@ -138,7 +138,7 @@ Pour des raisons de sécurité, cette option est désélectionnée par défaut. Lorsqu’elle est cochée, cette option autorise l’exécution de la méthode projet par le moteur SQL de 4D. Elle est désélectionnée par défaut, ce qui signifie que, sauf autorisation explicite, les méthodes projet de 4D sont protégées et ne peuvent pas être appelées par le moteur SQL de 4D. -This property applies to all internal and external SQL queries --- executed via the ODBC driver, SQL code inserted between the [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) tags or the [QUERY BY SQL](../commands-legacy/query-by-sql.md) command. +Cette propriété s'applique à toutes les requêtes SQL internes et externes --- exécutées via le driver ODBC, le code SQL inséré entre les balises [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) ou la commande [`QUERY BY SQL`](../commands-legacy/query-by-sql.md). **Notes :** @@ -149,15 +149,15 @@ Pour plus d’informations, reportez-vous à la section [Implémentations du mot #### Serveur REST -*Cette option est obsolète. Calling code through REST calls is only supported with [ORDA data model class functions](../REST/ClassFunctions.md).* +_Cette option est obsolète. L'appel de code par le biais d'appels REST n'est possible qu'avec les [fonctions de classe du modèle de données ORDA](../REST/ClassFunctions.md).\* #### Modifier attributs globalement -Using the "Attributes for methods" dialog box, you can modify an attribute (Invisible, Offered as a Web Service, etc.) for all or part of the database project methods in a single operation. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. +La boîte de dialogue "Attributs des méthodes" permet de modifier un attribut (Invisible, Disponible via Web Services etc.) pour tout ou partie des méthodes projet de la base de données en une seule opération. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. Pour modifier globalement les attributs des méthodes : -1. On the [Methods Page](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) of the 4D Explorer, expand the options menu, then choose the **Batch setting of attributes...** command. La boîte de dialogue **Attributs des méthodes** apparaît. +1. Dans la [Page Méthodes](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) de l'explorateur 4D, développez le menu des options, puis choisissez la commande **Modifier attributs globalement...**. La boîte de dialogue **Attributs des méthodes** apparaît. 2. Dans la zone “Méthodes à modifier”, saisissez une chaîne de caractères permettant de désigner les méthodes que vous souhaitez modifier globalement. La chaîne de caractères est utilisée comme critère de recherche des noms de méthodes. @@ -166,7 +166,7 @@ Utilisez le caractère générique @ pour vous aider à définir des groupes de - pour désigner les méthodes dont le nom débute par..., saisissez @ en fin de chaîne. Par exemple : `web@` - pour désigner les méthodes dont le nom contient..., saisissez @ en milieu de chaîne. Par exemple : `web@write` -- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `web@write` +- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `@write` - Pour désigner toutes les méthodes, il suffit de taper @ dans la zone. **Notes :** diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/components.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/components.md index 156224df92e516..4c006d9e688eac 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/components.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/Project/components.md @@ -3,115 +3,115 @@ id: components title: Composants --- -A 4D component is a set of 4D code and/or 4D forms representing one or more functionalities that you can add and use in your projects. For example, the [4D SVG](https://github.com/4d/4D-SVG) component adds advanced commands and an integrated rendering engine that can be used to display SVG files. +Un composant 4D est un ensemble de code 4D et de formulaires représentant une ou plusieurs fonctionnalité(s) que vous pouvez installer et utiliser dans vos projets. Par exemple, le composant [4D SVG](https://github.com/4d/4D-SVG) ajoute des commandes avancées et un moteur de rendu intégré qui peut être utilisé pour afficher des fichiers SVG. -You can [develop](../Extensions/develop-components.md) and [build](../Desktop/building.md) your own 4D components, or download public components shared by the 4D community that can be found on GitHub. +Vous pouvez [développer](../Extensions/develop-components.md) et [construire](../Desktop/building.md) vos propres composants 4D, ou télécharger des composants publics partagés par la communauté 4D qui se trouvent sur GitHub. -When developing in 4D, the component files can be transparently stored in your computer or on a Github repository. +Lorsque vous développez dans 4D, les fichiers de composants peuvent être stockés de manière transparente sur votre ordinateur ou sur un dépôt Github. -## Interpreted and compiled components +## Composants interprétés et compilés -Components can be interpreted or [compiled](../Desktop/building.md). +Les composants peuvent être interprétés ou [compilés](../Desktop/building.md). -- A 4D project running in interpreted mode can use either interpreted or compiled components. -- A 4D project running in compiled mode cannot use interpreted components. Dans ce cas, seuls les composants compilés peuvent être utilisés. +- Un projet 4D fonctionnant en mode interprété peut utiliser des composants interprétés ou compilés. +- Un projet 4D exécuté en mode compilé ne peut pas utiliser de composants interprétés. Dans ce cas, seuls les composants compilés peuvent être utilisés. -### Package folder +### Dossier racine (package) -The package folder of a component (*MyComponent.4dbase* folder) can contain: +Le dossier racine d'un composant (dossier *MyComponent.4dbase*) peut contenir : -- for **interpreted components**: a standard [Project folder](../Project/architecture.md). The package folder name must be suffixed with **.4dbase** if you want to install it in the [**Components** folder of your project](architecture.md#components). -- for **compiled components**: - - either a "Contents" folder containing a .4DZ file, a *Resources* folder, an *Info.plist* file (recommended architecture) - - or directly a .4DZ file with other folders such as *Resources*. +- pour les **composants interprétés** : un [dossier project](../Project/architecture.md) standard. Le nom du dossier du dossier racine doit être suffixé **.4dbase** si vous voulez l'installer dans le dossier [**Components**](architecture.md#components) de votre projet. +- pour les **composants compilés** : + - soit un dossier "Contents" contenant un fichier .4DZ, un dossier *Resources*, un fichier *Info.plist* (architecture recommandée) + - soit directement un fichier .4DZ avec d'autres dossiers tels que *Resources*. :::note -The "Contents" folder architecture is recommended for components if you want to [notarize](../Desktop/building.md#about-notarization) your applications on macOS. +L'architecture de dossier "Contents" est recommandée pour les composants si vous voulez [notariser](../Desktop/building.md#about-notarization) vos applications sur macOS. ::: -## Loading components +## Chargement des composants :::note -This page describes how to work with components in the **4D** and **4D Server** environments. In other environments, components are managed differently: +Cette page décrit comment travailler avec les composants dans les environnements **4D** et **4D Server**. Dans les autres environnements, les composants sont gérés différemment : -- in [4D in remote mode](../Desktop/clientServer.md), components are loaded by the server and sent to the remote application. -- in merged applications, components are [included at the build step](../Desktop/building.md#plugins--components-page). +- dans [4D en mode distant](../Desktop/clientServer.md), les composants sont chargés par le serveur et envoyés à l'application distante. +- dans les applications fusionnées, les composants sont [inclus à l'étape de construction](../Desktop/building.md#plugins--components-page). ::: ### Vue d’ensemble -To load a component in your 4D project, you can either: +Pour charger un composant dans votre projet 4D, vous pouvez soit : -- copy the component files in the [**Components** folder of your project](architecture.md#components) (interpreted component package folders must be suffixed with ".4dbase", see above), -- or, declare the component in the **dependencies.json** file of your project; this is done automatically for local files when you [**add a dependency using the Dependency manager interface**](#adding-a-github-dependency). +- copier les fichiers des composants dans le [dossier **Components** de votre projet](architecture.md#components) (les dossiers des composants interprétés doivent être suffixés avec ".4dbase", voir ci-dessus), +- ou déclarer le composant dans le fichier **dependencies.json** de votre projet ; ceci est fait automatiquement pour les fichiers locaux lorsque vous [**ajoutez une dépendance en utilisant l'interface du Gestionnaire de dépendances**](#adding-a-github-dependency). -Components declared in the **dependencies.json** file can be stored at different locations: +Les composants déclarés dans le fichier **dependencies.json** peuvent être stockés à différents endroits : -- at the same level as your 4D project's package folder: this is the default location, -- anywhere on your machine: the component path must be declared in the **environment4d.json** file -- on a GitHub repository: the component path can be declared in the **dependencies.json** file or in the **environment4d.json** file, or in both files. +- au même niveau que le dossier racine de votre projet 4D : c'est l'emplacement par défaut, +- n'importe où sur votre machine : le chemin du composant doit être déclaré dans le fichier **environment4d.json** +- sur un dépôt GitHub : le chemin du composant peut être déclaré dans le fichier **dependencies.json** ou dans le fichier **environment4d.json**, ou dans les deux. -If the same component is installed at different locations, a [priority order](#priority) is applied. +Si le même composant est installé à différents endroits, un [ordre de priorité](#priority) est appliqué. -### dependencies.json and environment4d.json +### dependencies.json et environment4d.json #### dependencies.json -The **dependencies.json** file references all components required in your 4D project. This file must be located in the **Sources** folder of the 4D project folder, e.g.: +Le fichier **dependencies.json** référence tous les composants nécessaires à votre projet 4D. Ce fichier doit être placé dans le dossier **Sources** du dossier du projet 4D, par exemple : ``` /MyProjectRoot/Project/Sources/dependencies.json ``` -It can contain: +Il peut contenir : -- names of components [stored locally](#local-components) (default path or path defined in an **environment4d.json** file), -- names of components [stored on GitHub repositories](#components-stored-on-github) (their path can be defined in this file or in an **environment4d.json** file). +- les noms des composants [stockés localement](#local-components) (chemin par défaut ou chemin défini dans un fichier **environment4d.json**), +- les noms des composants [stockés sur des dépôts GitHub](#components-stored-on-github) (leur chemin peut être défini dans ce fichier ou dans un fichier **environment4d.json**). #### environment4d.json -The **environment4d.json** file is optional. It allows you to define **custom paths** for some or all components declared in the **dependencies.json** file. This file can be stored in your project package folder or in one of its parent folders, at any level (up to the root). +Le fichier **environment4d.json** est facultatif. Il vous permet de définir des **chemins personnalisés** pour certains ou tous les composants déclarés dans le fichier **dependencies.json**. Ce fichier peut être stocké dans le dossier racine de votre projet ou dans l'un de ses dossiers parents, à n'importe quel niveau (jusqu'à la racine). -The main benefits of this architecture are the following: +Les principaux avantages de cette architecture sont les suivants : -- you can store the **environment4d.json** file in a parent folder of your projects and decide not to commit it, allowing you to have your local component organization. -- if you want to use the same GitHub repository for several of your projects, you can reference it in the **environment4d.json** file and declare it in the **dependencies.json** file. +- vous pouvez stocker le fichier **environment4d.json** dans un dossier parent de vos projets et décider de ne pas le livrer (*commit*), ce qui vous permet d'avoir une organisation locale pour vos composants. +- si vous souhaitez utiliser le même dépôt GitHub pour plusieurs de vos projets, vous pouvez le référencer dans le fichier **environment4d.json** et le déclarer dans le fichier **dependencies.json**. -### Priority +### Priorité -Since components can be installed in different ways, a priority order is applied when the same component is referenced at several locations: +Puisque les composants peuvent être installés de différentes manières, un ordre de priorité est appliqué lorsque le même composant est référencé à plusieurs endroits : -**Higest priority** +**Priorité la plus élevée** -1. Components stored in the [**Components** folder of the project](architecture.md#components). -2. Components declared in the **dependencies.json** file (the **environment4d.json** declared path overrides the **dependencies.json** path to configure a local environment). -3. Internal User 4D components (e.g. 4D NetKit, 4D SVG...) +1. Composants stockés dans le [dossier **Components** du projet](architecture.md#components). +2. Composants déclarés dans le fichier **dependencies.json** (le chemin déclaré dans **environment4d.json** remplace le chemin **dependencies.json** pour configurer un environnement local). +3. Composants utilisateurs 4D internes (par exemple 4D NetKit, 4D SVG...) -**Lowest priority** +**Priorité la plus basse** ```mermaid flowchart TB - id1("1
Components from project's Components folder") + id1("1
Composants du dossier Components du projet") ~~~ - id2("2
Components listed in dependencies.json") - ~~~ - id2 -- environment4d.json gives path --> id4("Load component based on path declared in environment4d.json") + id2("2
Composants listés dans dependencies.json") + ~~ + id2 -- environment4d.json donne le chemin --> id4("Charger le composant basé sur le chemin déclaré dans environment4d.json") ~~~ - id3("3
User 4D components") - id2 -- environment4d.json doesn't give path --> id5("Load component next to package folder") + id3("3
Composants utilisateurs 4D internes") + id2 -- environment4d.json ne donne pas de chemin --> id5("Charger le composant à côté du dossier raciner") ~~~ - id3("3
User 4D components") + id3("3
Composants utilisateurs 4D internes") ``` -When a component cannot be loaded because of another instance of the same component located at a higher priority level, both get a specific [status](#dependency-status): the non-loaded component is given the *Overloaded* status, while the loaded component has the *Overloading* status. +Lorsqu'un composant ne peut pas être chargé à cause d'une autre instance du même composant située à un niveau de priorité plus élevé, les deux obtiennent un [statut](#dependency-status) spécifique : le composant non chargé reçoit le statut *Overloaded*, tandis que le composant chargé a le statut *Overloading*. -### Local components +### Composants locaux -You declare a local component in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant local dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -122,28 +122,28 @@ You declare a local component in the [**dependencies.json** file](#dependenciesj } ``` -... where "myComponent1" and "myComponent2" are the name of the components to be loaded. +... où "myComponent1" et "myComponent2" sont les noms des composants à charger. -By default, if "myComponent1" and "myComponent2" are not declared in an [**environment4d.json**](#environment4djson) file, 4D will look for the component's package folder (*i.e.* the project root folder of the component) at the same level as your 4D project's package folder, e.g.: +Par défaut, si "myComponent1" et "myComponent2" ne sont pas déclarés dans un fichier [**environment4d.json**](#environment4djson), 4D cherchera le dossier package du composant (c'est-à-dire le dossier racine du projet du composant) au même niveau que le dossier du package de votre projet 4D, par exemple : ``` /MyProjectRoot/ /MyProjectComponentRoot/ ``` -Thanks to this architecture, you can simply copy all your components at the same level as your projects and reference them in your **dependencies.json** files. +Grâce à cette architecture, vous pouvez simplement copier tous vos composants au même niveau que vos projets et les référencer dans vos fichiers **dependencies.json**. :::note -If you do not want to use the **dependencies.json** architecture, you can install local components by copying their files in the [**Components** folder of your project](architecture.md#components). +Si vous ne souhaitez pas utiliser l'architecture **dependencies.json**, vous pouvez installer des composants locaux en copiant leurs fichiers dans le [dossier **Components** de votre projet](architecture.md#components). ::: -#### Customizing component paths +#### Personnalisation des chemins des composants -If you want to customize the location of local components, you declare the paths for the dependencies that are not stored at the same level as the project folder in the [**environment4d.json**](#environment4djson) file. +Si vous souhaitez personnaliser l'emplacement des composants locaux, vous devez déclarer dans le fichier [**environment4d.json**](#environment4djson) les chemins des dépendances qui ne sont pas stockées au même niveau que le dossier projet. -You can use **relative** or **absolute** paths (see below). +Vous pouvez utiliser des chemins **relatifs** ou **absolus** (voir ci-dessous). Exemples : @@ -159,43 +159,43 @@ Exemples : :::note -If a component path declared in the **environment4d.json** file is not found when the project is started, the component is not loaded and gets the *Not found* [status](#dependency-status), even if a version of the component exists next to the project's package folder. +Si un chemin de composant déclaré dans le fichier **environment4d.json** n'est pas trouvé lorsque le projet est démarré, le composant n'est pas chargé et récupère le [statut](#dependency-status) *Not found*, même si une version du composant existe à côté du dossier racine du projet. ::: -#### Relative paths vs absolute paths +#### Chemins relatifs vs chemins absolus -Paths are expressed in POSIX syntax as described in [this paragraph](../Concepts/paths#posix-syntax). +Les chemins sont exprimés en syntaxe POSIX comme décrit dans [ce paragraphe](../Concepts/paths#posix-syntax). -Relative paths are relative to the [`environment4d.json`](#environment4djson) file. Absolute paths are linked to the user's machine. +Les chemins relatifs sont relatifs au fichier [`environment4d.json`](#environment4djson). Les chemins absolus sont liés à la machine de l'utilisateur. -Using relative paths is **recommended** in most cases, since they provide flexibility and portability of the components architecture, especially if the project is hosted in a source control tool. +L'utilisation de chemins relatifs est **recommandée** dans la plupart des cas, puisqu'ils fournissent flexibilité et portabilité de l'architecture des composants, surtout si le projet est hébergé dans un outil de contrôle de source. -Absolute paths should only be used for components that are specific to one machine and one user. +Les chemins absolus ne doivent être utilisés que pour les composants spécifiques à une machine et à un utilisateur. -### Components stored on GitHub +### Composants stockés sur GitHub -4D components available as GitHub releases can be referenced and automatically loaded and updated in your 4D projects. +Des composants 4D disponibles en tant que releases GitHub peuvent être référencés et automatiquement chargés et mis à jour dans vos projets 4D. :::note -Regarding components stored on GitHub, both [**dependencies.json**](#dependenciesjson) and [**environment4d.json**](#environment4djson) files support the same contents. +En ce qui concerne les composants stockés sur GitHub, les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson) prennent en charge le même contenu. ::: -#### Configuring the GitHub repository +#### Configuration du dépôt GitHub -To be able to directly reference and use a 4D component stored on GitHub, you need to configure the GitHub component's repository: +Pour pouvoir référencer et utiliser directement un composant 4D stocké sur GitHub, vous devez configurer le dépôt du composant GitHub : -- Compress the component files in ZIP format. -- Name this archive with the same name as the GitHub repository. -- Integrate the archive into a [GitHub release](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) of the repository. +- Compressez les fichiers des composants au format ZIP. +- Nommez cette archive avec le même nom que le dépôt GitHub. +- Intégrez l'archive dans une [release GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) du dépôt. -These steps can easily be automated, with 4D code or using GitHub Actions, for example. +Ces étapes peuvent être facilement automatisées, avec du code 4D ou en utilisant des actions GitHub, par exemple. -#### Declaring paths +#### Déclaration des chemins -You declare a component stored on GitHub in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant stocké sur GitHub dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -208,7 +208,7 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -... where "myGitHubComponent1" is referenced and declared for the project, although "myGitHubComponent2" is only referenced. You need to declare it in the [**environment4d.json**](#environment4djson) file: +... où "myGitHubComponent1" est référencé et déclaré pour le projet, tandis que "myGitHubComponent2" est seulement référencé. Vous devez le déclarer dans le fichier [**environment4d.json**](#environment4djson) : ```json { @@ -220,13 +220,13 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -"myGitHubComponent2" can be used by several projects. +"myGitHubComponent2" peut être utilisé par plusieurs projets. -#### Tags and versions +#### Tags et versions -When a release is created in GitHub, it is associated to a **tag** and a **version**. The Dependency manager uses these information to handle automatic availability of components. +Lorsqu'une release est créée dans GitHub, elle est associée à un **tag** et à une **version**. Le gestionnaire de dépendances utilise ces informations pour gérer la disponibilité automatique des composants. -- **Tags** are texts that uniquely reference a release. In the [**dependencies.json** file](#dependenciesjson) and [**environment4d.json**](#environment4djson) files, you can indicate the release tag you want to use in your project. For example : +- Les **Tags** sont des textes qui référencent de manière unique une release. Dans les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson), vous pouvez indiquer le release tag que vous souhaitez utiliser dans votre projet. Par exemple : ```json { @@ -239,7 +239,7 @@ When a release is created in GitHub, it is associated to a **tag** and a **versi } ``` -- A release is also identified by a **version**. The versioning system used is based on the [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/) concept, which is the most commonly used. Each version number is identified as follows: `majorNumber.minorNumber.pathNumber`. In the same way as for tags, you can indicate the version of the component you wish to use in your project, as in this example: +- Une release est également identifiée par une **version**. Le système de versionnement utilisé est basé sur le concept de [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/), qui est le plus couramment utilisé. Chaque numéro de version est identifié comme suit : `majorNumber.minorNumber.pathNumber`. De la même manière que pour les tags, vous pouvez indiquer la version du composant que vous souhaitez utiliser dans votre projet, comme dans cet exemple : ```json { @@ -252,135 +252,135 @@ When a release is created in GitHub, it is associated to a **tag** and a **versi } ``` -A range is defined by two semantic versions, a min and a max, with operators '\< | > | >= | <= | ='. The `*` can be used as a placeholder for all versions. ~ and ^ prefixes define versions starting at a number, and up to respectively the next major and minor version. +Un intervalle est défini par deux versions sémantiques, un minimum et un maximum, avec les opérateurs "\< | > | >= | <= | =". Le `*` peut être utilisé comme substitut pour toutes les versions. Les préfixes ~ et ^ définissent les versions à partir d'un numéro, et jusqu'à respectivement la version majeure et mineure suivante. -Here are a few examples: +Voici quelques exemples : -- "latest": the version having the “latest” badge in GitHub releases. -- "\*": the latest version released. -- "1.\*": all version of major version 1. -- "1.2.\*": all patches of minor version 1.2. -- ">=1.2.3": the latest version, starting with the 1.2.3 version. -- ">1.2.3": the latest version, starting with the version just after the 1.2.3. -- "^1.2.3": the latest version 1, starting with the 1.2.3 version and strictly lower than version 2. -- "~1.2.3": the latest version 1.2, starting with the 1.2.3 version and strictly lower than version 1.3. -- "<=1.2.3": the latest version until the 1.2.3 one. -- "1.0.0 – 1.2.3" or ">=1.0.0 <=1.2.3": version between 1.0.0 and 1.2.3. -- "`<1.2.3 || >=2`": version that is not between 1.2.3 and 2.0.0. +- "latest" : la version ayant le badge "latest" dans les releases GitHub. +- "\*" : la dernière version publiée. +- "1.\*" : toutes les versions de la version majeure 1. +- "1.2.\*" : tous les correctifs de la version mineure 1.2. +- ">=1.2.3" : la dernière version, à partir de la version 1.2.3. +- ">1.2.3" : la dernière version, en commençant par la version juste après la 1.2.3. +- "^1.2.3" : la dernière version 1, à partir de la version 1.2.3 et strictement inférieure à la version 2. +- "~1.2.3" : la dernière version 1.2, à partir de la version 1.2.3 et strictement inférieure à la version 1.3. +- "<=1.2.3" : la dernière version jusqu'à la 1.2.3. +- "1.0.0 - 1.2.3" ou ">=1.0.0 <=1.2.3" : version comprise entre 1.0.0 et 1.2.3. +- "`<1.2.3 || >=2`" : version qui n'est pas comprise entre 1.2.3 et 2.0.0. -If you do not specify a tag or a version, 4D automatically retrieves the "latest" version. +Si vous ne spécifiez pas de tag ou de version, 4D récupère automatiquement la version "latest". -The Dependency manager checks periodically if component updates are available on Github. If a new version is available for a component, an update indicator is then displayed for the component in the dependency list, [depending on your settings](#defining-a-github-dependency-version-range). +Le Gestionnaire de dépendances vérifie périodiquement si des mises à jour de composants sont disponibles sur Github. Si une nouvelle version est disponible pour un composant, un indicateur de mise à jour est alors affiché pour le composant dans la liste des dépendances, [en fonction de vos paramètres](#defining-a-github-dependency-version-range). -#### Private repositories +#### Dépôts privés -If you want to integrate a component located in a private repository, you need to tell 4D to use a connection token to access it. +Si vous souhaitez intégrer un composant situé dans un référentiel privé, vous devez indiquer à 4D d'utiliser un token (*jeton*) de connexion pour y accéder. -To do this, in your GitHub account, create a **classic** token with access rights to **repo**. +Pour cela, dans votre compte GitHub, créez un token **classic** avec les droits d'accès au **dépôt**. :::note -For more information, please refer to the [GitHub token interface](https://github.com/settings/tokens). +Pour plus d'informations, veuillez vous référer à [GitHub token interface](https://github.com/settings/tokens). ::: -You then need to [provide your connection token](#providing-your-github-access-token) to the Dependency manager. +Vous devez ensuite [fournir votre token de connexion](#providing-your-github-access-token) au Gestionnaire de dépendances. -#### Local cache for dependencies +#### Cache local pour les dépendances -Referenced GitHub components are downloaded in a local cache folder then loaded in your environment. The local cache folder is stored at the following location: +Les composants GitHub référencés sont téléchargés dans un dossier de cache local puis chargés dans votre environnement. Le dossier de cache local est stocké à l'emplacement suivant : -- on macOs: `$HOME/Library/Caches//Dependencies` -- on Windows: `C:\Users\\AppData\Local\\Dependencies` +- sous macOs : `$HOME/Library/Caches//Dependencies` +- sous Windows : `C:\Users\\AppData\Local\\Dependencies` -...where `` can be "4D", "4D Server", or "tool4D". +...où `` peut être "4D", "4D Server" ou "tool4D". ### dependency-lock.json -A `dependency-lock.json` file is created in the [`userPreferences` folder](architecture.md#userpreferencesusername) of your project. +Un fichier `dependency-lock.json` est créé dans le dossier [`userPreferences`](architecture.md#userpreferencesusername) de votre projet. -This file logs information such as the state of dependencies, paths, urls, loading errors, as well as other information. It could be useful for component loading management or troubleshooting. +Ce fichier enregistre des informations telles que le statut des dépendances, les chemins d'accès, les Url, les erreurs de chargement, ainsi que d'autres informations. Il peut être utile pour la gestion du chargement de composants ou le dépannage. -## Monitoring Project Dependencies +## Suivi des dépendances du projet -In an opened project, you can add, remove, update, and get information about dependencies and their current loading status in the **Dependencies** panel. +Dans un projet ouvert, vous pouvez ajouter, supprimer, mettre à jour et obtenir des informations sur les dépendances et leur statut courant de chargement dans la fenêtre **Dépendances**. -To display the Dependencies panel: +Pour afficher la fenêtre Dépendances : -- with 4D, select the **Design/Project Dependencies** menu item (Development environment),
+- avec 4D, sélectionnez la ligne de menu **Développement/Dépendances du projet** (environnement de développement),
![dependency-menu](../assets/en/Project/dependency-menu.png) -- with 4D Server, select the **Window/Project Dependencies** menu item.
- ![dependency-menu-server](../assets/en/Project/dependency-menu-server.png) +- avec 4D Server, sélectionnez la ligne de menu **Fenêtre/Dépendances du projet**.
+ ![menu-dépendances-serveur](../assets/en/Project/dependency-menu-server.png) -The Dependencies panel is then displayed. Dependencies are sorted by name in alphabetical order: +La fenêtre Dépendances s'affiche alors. Les dépendances sont classées par nom par ordre alphabétique : ![dependency](../assets/en/Project/dependency.png) -The Dependencies panel interface allows you to manage dependencies (on 4D single-user and 4D Server). +L'interface de la fenêtre Dépendances vous permet de gérer les dépendances (sur 4D monoposte et 4D Server). -### Filtering dependencies +### Filtrer les dépendances -By default, all dependencies identified by the Dependency manager are listed, whatever their [status](#dependency-status). You can filter the displayed dependencies according to their status by selecting the appropriate tab at the top of the Dependencies panel: +Par défaut, toutes les dépendances identifiées par le Gestionnaire de dépendances sont listées, quel que soit leur [statut](#dependency-status). Vous pouvez filtrer les dépendances affichées en fonction de leur statut en sélectionnant l'onglet approprié en haut de la fenêtre : ![dependency-tabs](../assets/en/Project/dependency-tabs.png) -- **Active**: Dependencies that are loaded and can be used in the project. It includes *overloading* dependencies, which are actually loaded. *Overloaded* dependencies are listed in the **Conflicts** panel, along with all conflicting dependencies. -- **Inactive**: Dependencies that are not loaded in the project and are not available. There are many possible reasons for this status: missing files, version incompatibility... -- **Conflict**: Dependencies that are loaded but that overloads at least one other dependency at lower [priority level](#priority). Overloaded dependencies are also displayed so that you can check the origin of the conflict and take appropriate actions. +- **Actifs** : Dépendances chargées et utilisables dans le projet. Il comprend des dépendances *overloading*, qui sont effectivement chargées. Les dépendances *overloaded* sont listées dans l'onglet **Conflits**, ainsi que toutes les dépendances conflictuelles. +- **Inactifs** : Dépendances qui ne sont pas chargées dans le projet et qui ne sont pas disponibles. Diverses raisons peuvent expliquer ce statut : fichiers manquants, incompatibilité de version... +- **Conflit** : Dépendances qui sont chargées mais qui surchargent au moins une autre dépendance à un [niveau de priorité](#priority) inférieur. Les dépendances surchargées sont également affichées afin que vous puissiez vérifier l'origine du conflit et prendre les mesures appropriées. -### Dependency status +### Statut des dépendances -Dependencies requiring the developer's attention are indicated by a **status label** at the right side of the line and a specific background color: +Les dépendances nécessitant l'attention du développeur sont signalées par une **étiquette de statut** à droite de la ligne et une couleur de fond spécifique : ![dependency-status](../assets/en/Project/dependency-conflict2.png) -The following status labels are available: +Les étiquettes de statut suivantes sont disponibles : -- **Overloaded**: The dependency is not loaded because it is overloaded by another dependency with the same name at a higher [priority level](#priority). -- **Overloading**: The dependency is loaded and is overloading one or more other dependencies with the same name at a lower [priority level](#priority). -- **Not found**: The dependency is declared in the dependencies.json file but is not found. -- **Inactive**: The dependency is not loaded because it is not compatible with the project (e.g. the component is not compiled for the current platform). -- **Duplicated**: The dependency is not loaded because another dependency with the same name exists at the same location (and is loaded). -- **Available after restart**: The dependency reference has just been added or updated [using the interface](#monitoring-project-dependencies), it will be loaded once the application restarts. -- **Unloaded after restart**: The dependency reference has just been removed [using the interface](#removing-a-dependency), it will be unloaded once the application restarts. -- **Update available \**: A new version of the GitHub dependency matching your [component version configuration](#defining-a-github-dependency-version-range) has been detected. -- **Refreshed after restart**: The [component version configuration](#defining-a-github-dependency-version-range) of the GitHub dependency has been modified, it will be adjusted the next startup. -- **Recent update**: A new version of the GitHub dependency has been loaded at startup. +- **Overloaded** : La dépendance n'est pas chargée car elle est surchargée par une autre dépendance portant le même nom et ayant un [niveau de priorité](#priority) plus élevé. +- **Overloading** : La dépendance est chargée et surcharge une ou plusieurs autres dépendances avec le même nom à un [niveau de priorité](#priority) inférieur. +- **Non trouvé** : La dépendance est déclarée dans le fichier dependencies.json mais n'est pas trouvée. +- **Inactif** : La dépendance n'est pas chargée car elle n'est pas compatible avec le projet (par exemple, le composant n'est pas compilé pour la plate-forme actuelle). +- **Dupliqué** : La dépendance n'est pas chargée car une autre dépendance portant le même nom existe au même endroit (et est chargée). +- **Disponible après redémarrage** : La référence de la dépendance vient d'être ajoutée ou mise à jour [à l'aide de l'interface](#monitoring-project-dependencies), elle sera chargée une fois que l'application aura redémarré. +- **Déchargé après redémarrage** : La référence à la dépendance vient d'être supprimée [en utilisant l'interface](#removing-a-dependency), elle sera déchargée une fois que l'application aura redémarré. +- **Mise à jour disponible \** : Une nouvelle version de la dépendance GitHub correspondant à votre [configuration de version du composant](#defining-a-github-dependency-version-range) a été détectée. +- **Actualisé après redémarrage** : La [configuration de version](#defining-a-github-dependency-version-range) de la dépendance GitHub a été modifiée, elle sera ajustée au prochain démarrage. +- **Mise à jour récente** : Une nouvelle version de la dépendance GitHub a été chargée au démarrage. -A tooltip is displayed when you hover over the dependency line, provding additional information about the status: +Une infobulle s'affiche lorsque vous survolez la ligne de dépendance, fournissant des informations supplémentaires sur le statut : ![dependency-tips](../assets/en/Project/dependency-tip1.png) -### Dependency origin +### Origine de la dépendance -The Dependencies panel lists all project dependencies, whatever their origin, i.e. wherever they come from. The dependency origin is provided by the tag under its name: +Le panneau Dépendances liste toutes les dépendances du projet, quelle que soit leur origine, c'est-à-dire d'où qu'elles viennent. L'origine de la dépendance est fournie par l'étiquette sous son nom : ![dependency-origin](../assets/en/Project/dependency-origin.png) -The following origins are possible: +Les options suivantes sont disponibles : -| Origin tag | Description | +| Étiquette d'origine | Description | | --------------------------------- | ------------------------------------------------------------------------------ | -| 4D Component | Built-in 4D component, stored in the `Components` folder of the 4D application | -| dependencies.json | Component declared in the [`dependencies.json`](#dependenciesjson) file | -| Environment | Component declared in the [`environnement4d.json`](#environment4djson) file | -| Project Component | Component located in the [`Components`](architecture.md#components) folder | +| Composant 4D | Composant 4D intégré, stocké dans le dossier `Components` de l'application 4D | +| dependencies.json | Composant déclaré dans le fichier [`dependencies.json`](#dependenciesjson) | +| Environnement | Composant déclaré dans le fichier [`environnement4d.json`](#environment4djson) | +| Composant du projet | Composant situé dans le dossier [`Components`](architecture.md#components) | -**Right-click** in a dependency line and select **Show on disk** to reveal the location of a dependency: +**Cliquez avec le bouton droit de la souris** dans une ligne de dépendance et sélectionnez **Afficher sur le disque** pour révéler l'emplacement d'une dépendance : ![dependency-show](../assets/en/Project/dependency-show.png) :::note -This item is not displayed if the dependency is inactive because its files are not found. +Cet élément n'est pas affiché si la dépendance est inactive parce que ses fichiers sont introuvables. ::: -Component icon and location logo provide additional information: +L'icône du composant et le logo de l'emplacement fournissent des informations supplémentaires : -- The component logo indicates if it is provided by 4D or a third-party developer. -- Local components can be differentiated from GitHub components by a small icon. +- Le logo du composant indique s'il est fourni par 4D ou par un développeur tiers. +- Les composants locaux peuvent être différenciés des composants GitHub par une petite icône. ![dependency-origin](../assets/en/Project/dependency-github.png) diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$attributes.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$attributes.md index d5210c3aa0ea91..68e3e192e83f70 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$attributes.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$attributes.md @@ -3,11 +3,11 @@ id: attributes title: $attributes --- -Allows selecting the attribute(s) to get from the dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, or `Employee?$attributes=employer.name`). +Permet de sélectionner le ou les attribut(s) à obtenir de la dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, ou `Employee?$attributes=employer.name`). ## Description -If you have relation attributes in a dataclass, use `$attributes` to define the path of attributes whose values you want to get for the related entity or entities. +Lorsque vous avez des attributs relationnels dans une dataclass, utilisez `$attributes` pour définir le chemin des attributs dont vous souhaitez obtenir les valeurs pour l'entité ou les entités associée(s). Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) ou à une entity selection (par exemple, People/$entityset/0AF4679A5C394746BFEB68D2162A19FF). @@ -22,8 +22,8 @@ Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) - `$attributes=relatedEntities.*` : toutes les propriétés des entités liées sont retournées - `$attributes=relatedEntities.attributePath1, relatedEntity.attributePath2, ...` : seuls ces attributs des entités liées sont retournés. -- If `$attributes` is specified for **storage** attributes: - - `$attributes=attribute1, attribute2, ...`: only those attributes of the entities are returned. +- Si `$attributes` est spécifié pour les attributs **storage** : + - `$attributes=attribute1, attribute2, ...` : seuls les attributs des entités sont renvoyés. ## Exemple avec plusieurs entités liées diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md index 3e5da3f941b00f..2a3fac86364d9c 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md @@ -36,7 +36,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, **Réponse** : -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Chaîne, vou **Réponse** : -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Si vous souhaitez obtenir un calcul avec un attribut, vous pouvez écrire ce qui **Réponse** : -`235000` +`335000` Si vous souhaitez effectuer un calcul avec un attribut Objet, vous pouvez saisir ce qui suit : diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/code-editor/write-class-method.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/code-editor/write-class-method.md index 2930df9da1966c..1dec914a77eeee 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/code-editor/write-class-method.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R8/code-editor/write-class-method.md @@ -15,7 +15,7 @@ L'éditeur de code 4D fournit un contrôle de base des erreurs de syntaxe. Un co :::note -If you are used to coding with **VS Code**, you can also use this editor with 4D code after installing the [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) extension. +Si vous avez l'habitude de coder avec **VS Code**, vous pouvez également utiliser cet éditeur avec le Langage 4D après avoir installé l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode). ::: @@ -33,7 +33,7 @@ Chaque fenêtre de l'éditeur de code dispose d'une barre d'outils qui permet un | **Déployer tout / Contracter tout** | ![expand-collapse-button](../assets/en/code-editor/expand-collapse-all.png) | Ces boutons permettent de déployer ou de contracter toutes les structures de flux de contrôle du code. | | **Informations sur la méthode** | ![method-information-icon](../assets/en/code-editor/method-information.png) | Affiche la boîte de dialogue [Propriétés de la méthode](../Project/code-overview.md#project-method-properties) (méthodes de projet uniquement). | | **Dernières valeurs du presse-papiers** | ![last-clipboard-values-icon](../assets/en/code-editor/last-clipboard-values.png) | Affiche les dernières valeurs stockées dans le presse-papiers. | -| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. You can [use these clipboards](#clipboards) by clicking on them directly or by using keyboard shortcuts. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | +| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. Vous pouvez [utiliser ces presse-papiers](#clipboards) en cliquant directement dessus ou en utilisant des raccourcis clavier. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | | **Menu déroulant de navigation** | ![code-navigation-icons](../assets/en/code-editor/tags.png) | Vous permet de naviguer à l'intérieur des méthodes et des classes avec du contenu étiqueté automatiquement ou des marqueurs déclarés manuellement. Voir ci-dessous | ### Zone d'édition @@ -368,7 +368,7 @@ La liste est par ordre alphabétique. Choisissez la valeur en double-cliquant de Par défaut, vous pouvez également insérer une valeur suggérée en appuyant sur l'un des délimiteurs suivants `( ; : = < [ {` après avoir sélectionné une valeur : la valeur insérée est ensuite suivie du délimiteur, prête pour la saisie des données. -![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** key --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) +![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** touche --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) > Vous pouvez désactiver l'utilisation de délimiteurs pour insérer des valeurs suggérées dans les **Préférences** > **Méthodes** > **Options**. diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/CollectionClass.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/CollectionClass.md index b9c66273b1b1ef..2fe0745e563ccd 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/CollectionClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/CollectionClass.md @@ -82,10 +82,10 @@ Une collection est initialisée avec les commandes [`New collection`](../command -| Paramètres | Type | | Description | -| ---------- | ------- | :-------------------------: | ----------------------------- | -| index | Integer | -> | Index de l'élément à renvoyer | -| Résultat | any | <- | L'élément à cet index | +| Paramètres | Type | | Description | +| ---------- | ------- | :-------------------------: | ------------------------------ | +| index | Integer | -> | Indice de l'élément à renvoyer | +| Résultat | any | <- | L'élément à cet indice | diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/FileClass.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/FileClass.md index b749728656fa0e..0384f822c7a99b 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/FileClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/API/FileClass.md @@ -249,10 +249,10 @@ Vous souhaitez supprimer un fichier spécifique dans le dossier de la base de do
Historique -| Release | Modifications | -| ------- | ------------------------------- | -| 20 R9 | Read UUIDs in macOS executables | -| 19 | Ajout | +| Release | Modifications | +| ------- | -------------------------------------------- | +| 20 R9 | Lecture des UUIDs dans les exécutables macOS | +| 19 | Ajout |
@@ -260,19 +260,19 @@ Vous souhaitez supprimer un fichier spécifique dans le dossier de la base de do -| Paramètres | Type | | Description | -| ---------- | ------ | --------------------------- | ---------------------------- | -| Résultat | Object | <- | Application file information | +| Paramètres | Type | | Description | +| ---------- | ------ | --------------------------- | -------------------------------------------- | +| Résultat | Object | <- | Informations sur le fichier de l'application | #### Description -The `.getAppInfo()` function returns the contents of an application file information as an object. +La fonction `.getAppInfo()` renvoie le contenu des informations d'un fichier d'application sous la forme d'un objet. -The function must be used with an existing, supported file: **.plist** (all platforms), **.exe**/**.dll** (Windows), or **macOS executable**. If the file does not exist on disk or is not a supported file, the function returns an empty object (no error is generated). +La fonction doit être utilisée avec un fichier existant et pris en charge : **.plist** (toutes les plateformes), **.exe**/**.dll** (Windows), ou **exécutable macOS**. Si le fichier n'existe pas sur le disque ou n'est pas un fichier pris en charge, la fonction renvoie un objet vide (aucune erreur n'est générée). -**Returned object with a .plist file (all platforms)** +**Objet retourné avec un fichier .plist (toutes les plateformes)** Le contenu du fichier xml est analysé et les clés sont renvoyées en tant que propriétés de l'objet, en préservant leur type (texte, booléen, numérique). `.plist dict` est renvoyé sous forme d'objet JSON et `.plist array` est renvoyé sous forme de tableau JSON. @@ -282,7 +282,7 @@ Cette fonction ne prend en charge que les fichiers .plist au format xml (texte). ::: -**Returned object with a .exe or .dll file (Windows only)** +**Objet retourné avec un fichier .exe ou .dll (Windows uniquement)** Toutes les valeurs de propriétés sont de type Texte. @@ -297,11 +297,11 @@ Toutes les valeurs de propriétés sont de type Texte. | FileVersion | Text | | OriginalFilename | Text | -**Returned object with a macOS executable file (macOS only)** +**Objet retourné avec un fichier exécutable macOS (macOS uniquement)** :::note -A macOS executable file is located within a package (e.g. myApp.app/Contents/MacOS/myApp). +Un fichier exécutable macOS est situé dans un package (par exemple, myApp.app/Contents/MacOS/myApp). ::: @@ -568,11 +568,11 @@ Vous souhaitez que "ReadMe.txt" soit renommé "ReadMe_new.txt" :
Historique -| Release | Modifications | -| ------- | ------------------------------- | -| 20 R9 | Read UUIDs in macOS executables | -| 20 | Prise en charge de WinIcon | -| 19 | Ajout | +| Release | Modifications | +| ------- | -------------------------------------------- | +| 20 R9 | Lecture des UUIDs dans les exécutables macOS | +| 20 | Prise en charge de WinIcon | +| 19 | Ajout |
@@ -590,7 +590,7 @@ Vous souhaitez que "ReadMe.txt" soit renommé "ReadMe_new.txt" : The `.setAppInfo()` function writes the *info* properties as information contents of an application file. -The function must be used with an existing, supported file: **.plist** (all platforms), **.exe**/**.dll** (Windows), or **macOS executable**. If the file does not exist on disk or is not a supported file, the function does nothing (no error is generated). +La fonction doit être utilisée avec un fichier existant et pris en charge : **.plist** (toutes les plateformes), **.exe**/**.dll** (Windows), ou **exécutable macOS**. If the file does not exist on disk or is not a supported file, the function does nothing (no error is generated). ***info* parameter object with a .plist file (all platforms)** diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/code-overview.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/code-overview.md index 50a421c31f9323..99c6fe979d10ec 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/code-overview.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/code-overview.md @@ -1,26 +1,26 @@ --- id: code-overview -title: Methods and classes +title: Méthodes et classes --- -The 4D code used across your project is written in [methods](../Concepts/methods.md) and [classes](../Concepts/classes.md). +Le code 4D utilisé dans votre projet est écrit dans des [méthodes](../Concepts/methods.md) et des [classes](../Concepts/classes.md). -L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. You will usually use the included 4D [code editor](../code-editor/write-class-method.md) to work with your code. You can also use other editors such as **VS Code**, for which the [4D-Analyzer extension](https://github.com/4d/4D-Analyzer-VSCode) is available. +L'IDE de 4D vous offre diverses fonctionnalités pour créer, modifier, exporter ou supprimer votre code. Vous utiliserez généralement l'[éditeur intégré de code 4D](../code-editor/write-class-method.md) pour travailler avec votre code. Vous pouvez également utiliser d'autres éditeurs tels que **VS Code**, pour lesquels l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) est disponible. ## Créer des méthodes -A method in 4D is stored in a **.4dm** file located in the appropriate folder of the [`/Project/Sources/`](../Project/architecture.md#sources) folder. +Une méthode dans 4D est stockée dans un fichier **.4dm** situé dans le dossier approprié du dossier [`/Project/Sources/`](../Project/architecture.md#sources). Vous pouvez créer [plusieurs types de méthodes](../Concepts/methods.md) : -- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes Objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). -- Project methods can also be created or opened from the **File** menu or toolbar (**New/Method...** or **Open/Method...**) or using shortcuts in the [Code editor window](../code-editor/write-class-method.md#shortcuts). +- Tous les types de méthodes peuvent être créés ou ouverts à partir de la fenêtre de l'**Explorateur** (à l'exception des méthodes objet qui sont gérées à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md)). +- Les méthodes projet peuvent également être créées ou ouvertes à partir du menu **Fichier** ou de la barre d'outils (**Nouveau/Méthode...** ou **Ouvrir/Méthode...**) ou à l'aide de raccourcis dans la [fenêtre de l'éditeur de code](../code-editor/write-class-method.md#shortcuts). - Les triggers peuvent également être créés ou ouverts à partir de l'éditeur de Structure. - Les méthodes formulaire peuvent également être créées ou ouvertes à partir de l'[éditeur de formulaires](../FormEditor/formEditor.md). ## Créer des classes -A user class in 4D is defined by a specific method file (**.4dm**), stored in the [`/Project/Sources/Classes/`](../Project/architecture.md#sources) folder. Le nom du fichier est le nom de la classe. +Une classe utilisateur dans 4D est définie par un fichier de méthode spécifique (**.4dm**), stocké dans le dossier [`/Project/Sources/Classes/`](../Project/architecture.md#sources). Le nom du fichier est le nom de la classe. Vous pouvez créer un fichier de classe à partir du menu ou de la barre d'outils **Fichier** (**Nouveau/Classe...**) ou dans la page **Méthodes** de la fenêtre de l'**Explorateur** . @@ -31,13 +31,13 @@ Pour plus d'informations, reportez-vous à la section [Classes](../Concepts/clas Pour supprimer une méthode ou une classe existante, vous pouvez : - sur votre disque, supprimer le fichier *.4dm* du dossier "Sources", -- in the 4D Explorer, select the method or class and click ![](../assets/en/Users/MinussNew.png) or choose **Move to Trash** from the contextual menu. +- dans l'explorateur de 4D, sélectionnez la méthode ou la classe et cliquez sur ![](../assets/en/Users/MinussNew.png) ou choisissez **Déplacer vers la corbeille** dans le menu contextuel. > Pour supprimer une méthode objet, choisissez **Supprimer la méthode objet** dans l'[éditeur de formulaires](../FormEditor/formEditor.md) (menu **Objet** ou menu contextuel). ## Importer et exporter le code -Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. These commands are found in the **Method** menu of the [Code editor](../code-editor/write-class-method.md). +Vous pouvez importer et exporter une méthode ou le code d'une classe sous la forme d'un fichier. Ces commandes se trouvent dans le menu **Méthode** de l'[éditeur de code](../code-editor/write-class-method.md). - Lorsque vous sélectionnez la commande **Exporter la méthode...** , une boîte de dialogue standard d'enregistrement de fichier apparaît, vous permettant de choisir le nom, l'emplacement et le format du fichier d'export (voir ci-dessous). Comme pour l'impression, l'export ne tient pas compte de l'état contracté des structures de code et le code entier est exporté. - Lorsque vous sélectionnez la commande **Importer la méthode...**, une boîte de dialogue standard d'ouverture de fichier standard apparaît, vous permettant de désigner le fichier à importer. L'importation remplace le texte sélectionné dans la méthode. Pour remplacer une méthode existante par une méthode importée, il suffit de sélectionner l’ensemble du contenu de la méthode avant d’effectuer l’importation. @@ -57,8 +57,8 @@ Les autres types de méthodes n'ont pas de propriétés spécifiques. Leurs prop Pour afficher la boîte de dialogue **Propriétés de la méthode** pour une méthode projet, vous pouvez soit : -- in the [Code Editor](../code-editor/write-class-method.md), select the **Method Properties...** command in the **Method** menu, -- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Propriétés de la méthode.** dans le menu contextuel ou dans le menu d'options. +- dans l'[éditeur de code](../code-editor/write-class-method.md), sélectionnez la commande **Propriétés de la méthode...** dans le menu **Méthode**, +- ou dans la page **Méthodes** de l'Explorateur, **clic droit** sur la méthode projet et sélectionner **Modifier les propriétés** dans le menu contextuel ou dans le menu d'options. > Une fonction de paramétrage global vous permet de modifier une propriété pour tout ou partie des méthodes projet en une seule opération (voir [Modifier attributs globalement](#modifier-attributs-globalement)). @@ -106,7 +106,7 @@ Pour plus d'informations sur cette option, reportez-vous à [Attribut Exécuter ### Mode d’exécution -Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. It is described in the [Preemptive processes section](../Develop/preemptive.md). +Cette option vous permet de déclarer la méthode éligible à l'exécution en mode préemptif. Elle est décrite dans la section [Process préemptifs](../Develop/preemptive.md). ### Disponibilité @@ -116,7 +116,7 @@ Les attributs de disponibilité précisent les services externes autorisés à a Cet attribut vous permet de publier la méthode courante comme service Web accessible via des requêtes SOAP. Pour plus d’informations, reportez-vous au chapitre [Publication et utilisation de Services Web](https://doc.4d.com/4Dv20/4D/20.2/Publication-and-use-of-Web-Services.200-6750103.en.html). Lorsque cette option est cochée, l’option **Publié dans WSDL** est active. -In the Explorer, project methods that are offered as a Web Service are given a specific icon. +Dans l'explorateur, les méthodes projet qui sont proposées en tant que service Web sont dotées d'une icône spécifique. **Note :** Il n'est pas possible de publier en tant que Web service une méthode dont le nom comporte des caractères non conformes à la nomenclature XML (par exemple des espaces). Si le nom de la méthode n'est pas conforme, 4D refuse l'affectation de la propriété. @@ -124,13 +124,13 @@ In the Explorer, project methods that are offered as a Web Service are given a s Cet attribut est actif uniquement si l'attribut "Web service" est coché. Il permet d’inclure la méthode courante dans le fichier WSDL de l’application 4D. Pour plus d’informations sur ce point, reportez-vous au paragraphe [Génération du WSDL](https://doc.4d.com/4Dv20/4D/20.2/Publishing-a-Web-Service-with-4D.300-6750334.en.html#502689). -In the Explorer, project methods that are offered as a Web Service and published in WSDL are given a specific icon. +Dans l'explorateur, les méthodes projet proposées en tant que service Web et publiées dans le WSDL sont dotées d'une icône spécifique. #### Balises HTML et URLs 4D (4DACTION...) -This option is used to reinforce 4D Web server security: when it is not checked, the project method cannot be executed via an HTTP request containing the special [4DACTION URL](../WebServer/httpRequests.md#4daction) used for calling 4D methods, nor the special [4DSCRIPT, 4DTEXT and 4DHTML tags](../Tags/transformation-tags.md). +Cette option permet de renforcer la sécurité du serveur Web 4D : lorsqu'elle n'est pas cochée, la méthode projet ne peut pas être exécutée via une requête HTTP contenant l'URL spéciale [4DACTION](../WebServer/httpRequests.md#4daction) utilisée pour appeler les méthodes 4D, ni les balises spéciales [4DSCRIPT, 4DTEXT et 4DHTML](../Tags/transformation-tags.md). -In the Explorer, project methods with this attribute are given a specific icon. +Dans l'explorateur, les méthodes projet ayant cet attribut sont dotées d'une icône spécifique. Pour des raisons de sécurité, cette option est désélectionnée par défaut. Vous devez désigner individuellement chaque méthode pouvant être exécutée via les URLs et les balises spéciales. @@ -138,7 +138,7 @@ Pour des raisons de sécurité, cette option est désélectionnée par défaut. Lorsqu’elle est cochée, cette option autorise l’exécution de la méthode projet par le moteur SQL de 4D. Elle est désélectionnée par défaut, ce qui signifie que, sauf autorisation explicite, les méthodes projet de 4D sont protégées et ne peuvent pas être appelées par le moteur SQL de 4D. -This property applies to all internal and external SQL queries --- executed via the ODBC driver, SQL code inserted between the [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) tags or the [QUERY BY SQL](../commands-legacy/query-by-sql.md) command. +Cette propriété s'applique à toutes les requêtes SQL internes et externes --- exécutées via le driver ODBC, le code SQL inséré entre les balises [Begin SQL](../commands-legacy/begin-sql.md)/[End SQL](../commands-legacy/end-sql.md) ou la commande [`QUERY BY SQL`](../commands-legacy/query-by-sql.md). **Notes :** @@ -149,15 +149,15 @@ Pour plus d’informations, reportez-vous à la section [Implémentations du mot #### Serveur REST -*Cette option est obsolète. Calling code through REST calls is only supported with [ORDA data model class functions](../REST/ClassFunctions.md).* +_Cette option est obsolète. L'appel de code par le biais d'appels REST n'est possible qu'avec les [fonctions de classe du modèle de données ORDA](../REST/ClassFunctions.md).\* #### Modifier attributs globalement -Using the "Attributes for methods" dialog box, you can modify an attribute (Invisible, Offered as a Web Service, etc.) for all or part of the database project methods in a single operation. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. +La boîte de dialogue "Attributs des méthodes" permet de modifier un attribut (Invisible, Disponible via Web Services etc.) pour tout ou partie des méthodes projet de la base de données en une seule opération. Cette fonction est très utile pour modifier les attributs d’un grand nombre de méthodes projet. Elle peut également être utilisée en cours de développement pour appliquer rapidement des attributs communs à des groupes homogènes de méthodes. Pour modifier globalement les attributs des méthodes : -1. On the [Methods Page](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) of the 4D Explorer, expand the options menu, then choose the **Batch setting of attributes...** command. La boîte de dialogue **Attributs des méthodes** apparaît. +1. Dans la [Page Méthodes](https://doc.4d.com/4Dv20/4D/20.2/Methods-Page.300-6750119.en.html) de l'explorateur 4D, développez le menu des options, puis choisissez la commande **Modifier attributs globalement...**. La boîte de dialogue **Attributs des méthodes** apparaît. 2. Dans la zone “Méthodes à modifier”, saisissez une chaîne de caractères permettant de désigner les méthodes que vous souhaitez modifier globalement. La chaîne de caractères est utilisée comme critère de recherche des noms de méthodes. @@ -166,7 +166,7 @@ Utilisez le caractère générique @ pour vous aider à définir des groupes de - pour désigner les méthodes dont le nom débute par..., saisissez @ en fin de chaîne. Par exemple : `web@` - pour désigner les méthodes dont le nom contient..., saisissez @ en milieu de chaîne. Par exemple : `web@write` -- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `web@write` +- pour désigner les méthodes dont le nom se termine par..., saisissez @ en début de chaîne. Par exemple : `@write` - Pour désigner toutes les méthodes, il suffit de taper @ dans la zone. **Notes :** diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/components.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/components.md index 829e24c1b861e4..04b56bdbb2aa11 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/components.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/Project/components.md @@ -3,115 +3,115 @@ id: components title: Composants --- -A 4D component is a set of 4D code and/or 4D forms representing one or more functionalities that you can add and use in your projects. For example, the [4D SVG](https://github.com/4d/4D-SVG) component adds advanced commands and an integrated rendering engine that can be used to display SVG files. +Un composant 4D est un ensemble de code 4D et de formulaires représentant une ou plusieurs fonctionnalité(s) que vous pouvez installer et utiliser dans vos projets. Par exemple, le composant [4D SVG](https://github.com/4d/4D-SVG) ajoute des commandes avancées et un moteur de rendu intégré qui peut être utilisé pour afficher des fichiers SVG. -You can [develop](../Extensions/develop-components.md) and [build](../Desktop/building.md) your own 4D components, or download public components shared by the 4D community that can be found on GitHub. +Vous pouvez [développer](../Extensions/develop-components.md) et [construire](../Desktop/building.md) vos propres composants 4D, ou télécharger des composants publics partagés par la communauté 4D qui se trouvent sur GitHub. -When developing in 4D, the component files can be transparently stored in your computer or on a Github repository. +Lorsque vous développez dans 4D, les fichiers de composants peuvent être stockés de manière transparente sur votre ordinateur ou sur un dépôt Github. -## Interpreted and compiled components +## Composants interprétés et compilés -Components can be interpreted or [compiled](../Desktop/building.md). +Les composants peuvent être interprétés ou [compilés](../Desktop/building.md). -- A 4D project running in interpreted mode can use either interpreted or compiled components. -- A 4D project running in compiled mode cannot use interpreted components. Dans ce cas, seuls les composants compilés peuvent être utilisés. +- Un projet 4D fonctionnant en mode interprété peut utiliser des composants interprétés ou compilés. +- Un projet 4D exécuté en mode compilé ne peut pas utiliser de composants interprétés. Dans ce cas, seuls les composants compilés peuvent être utilisés. -### Package folder +### Dossier racine (package) -The package folder of a component (*MyComponent.4dbase* folder) can contain: +Le dossier racine d'un composant (dossier *MyComponent.4dbase*) peut contenir : -- for **interpreted components**: a standard [Project folder](../Project/architecture.md). The package folder name must be suffixed with **.4dbase** if you want to install it in the [**Components** folder of your project](architecture.md#components). -- for **compiled components**: - - either a "Contents" folder containing a .4DZ file, a *Resources* folder, an *Info.plist* file (recommended architecture) - - or directly a .4DZ file with other folders such as *Resources*. +- pour les **composants interprétés** : un [dossier project](../Project/architecture.md) standard. Le nom du dossier du dossier racine doit être suffixé **.4dbase** si vous voulez l'installer dans le dossier [**Components**](architecture.md#components) de votre projet. +- pour les **composants compilés** : + - soit un dossier "Contents" contenant un fichier .4DZ, un dossier *Resources*, un fichier *Info.plist* (architecture recommandée) + - soit directement un fichier .4DZ avec d'autres dossiers tels que *Resources*. :::note -The "Contents" folder architecture is recommended for components if you want to [notarize](../Desktop/building.md#about-notarization) your applications on macOS. +L'architecture de dossier "Contents" est recommandée pour les composants si vous voulez [notariser](../Desktop/building.md#about-notarization) vos applications sur macOS. ::: -## Loading components +## Chargement des composants :::note -This page describes how to work with components in the **4D** and **4D Server** environments. In other environments, components are managed differently: +Cette page décrit comment travailler avec les composants dans les environnements **4D** et **4D Server**. Dans les autres environnements, les composants sont gérés différemment : -- in [4D in remote mode](../Desktop/clientServer.md), components are loaded by the server and sent to the remote application. -- in merged applications, components are [included at the build step](../Desktop/building.md#plugins--components-page). +- dans [4D en mode distant](../Desktop/clientServer.md), les composants sont chargés par le serveur et envoyés à l'application distante. +- dans les applications fusionnées, les composants sont [inclus à l'étape de construction](../Desktop/building.md#plugins--components-page). ::: ### Vue d’ensemble -To load a component in your 4D project, you can either: +Pour charger un composant dans votre projet 4D, vous pouvez soit : -- copy the component files in the [**Components** folder of your project](architecture.md#components) (interpreted component package folders must be suffixed with ".4dbase", see above), -- or, declare the component in the **dependencies.json** file of your project; this is done automatically for local files when you [**add a dependency using the Dependency manager interface**](#adding-a-github-dependency). +- copier les fichiers des composants dans le [dossier **Components** de votre projet](architecture.md#components) (les dossiers des composants interprétés doivent être suffixés avec ".4dbase", voir ci-dessus), +- ou déclarer le composant dans le fichier **dependencies.json** de votre projet ; ceci est fait automatiquement pour les fichiers locaux lorsque vous [**ajoutez une dépendance en utilisant l'interface du Gestionnaire de dépendances**](#adding-a-github-dependency). -Components declared in the **dependencies.json** file can be stored at different locations: +Les composants déclarés dans le fichier **dependencies.json** peuvent être stockés à différents endroits : -- at the same level as your 4D project's package folder: this is the default location, -- anywhere on your machine: the component path must be declared in the **environment4d.json** file -- on a GitHub repository: the component path can be declared in the **dependencies.json** file or in the **environment4d.json** file, or in both files. +- au même niveau que le dossier racine de votre projet 4D : c'est l'emplacement par défaut, +- n'importe où sur votre machine : le chemin du composant doit être déclaré dans le fichier **environment4d.json** +- sur un dépôt GitHub : le chemin du composant peut être déclaré dans le fichier **dependencies.json** ou dans le fichier **environment4d.json**, ou dans les deux. -If the same component is installed at different locations, a [priority order](#priority) is applied. +Si le même composant est installé à différents endroits, un [ordre de priorité](#priority) est appliqué. -### dependencies.json and environment4d.json +### dependencies.json et environment4d.json #### dependencies.json -The **dependencies.json** file references all components required in your 4D project. This file must be located in the **Sources** folder of the 4D project folder, e.g.: +Le fichier **dependencies.json** référence tous les composants nécessaires à votre projet 4D. Ce fichier doit être placé dans le dossier **Sources** du dossier du projet 4D, par exemple : ``` /MyProjectRoot/Project/Sources/dependencies.json ``` -It can contain: +Il peut contenir : -- names of components [stored locally](#local-components) (default path or path defined in an **environment4d.json** file), -- names of components [stored on GitHub repositories](#components-stored-on-github) (their path can be defined in this file or in an **environment4d.json** file). +- les noms des composants [stockés localement](#local-components) (chemin par défaut ou chemin défini dans un fichier **environment4d.json**), +- les noms des composants [stockés sur des dépôts GitHub](#components-stored-on-github) (leur chemin peut être défini dans ce fichier ou dans un fichier **environment4d.json**). #### environment4d.json -The **environment4d.json** file is optional. It allows you to define **custom paths** for some or all components declared in the **dependencies.json** file. This file can be stored in your project package folder or in one of its parent folders, at any level (up to the root). +Le fichier **environment4d.json** est facultatif. Il vous permet de définir des **chemins personnalisés** pour certains ou tous les composants déclarés dans le fichier **dependencies.json**. Ce fichier peut être stocké dans le dossier racine de votre projet ou dans l'un de ses dossiers parents, à n'importe quel niveau (jusqu'à la racine). -The main benefits of this architecture are the following: +Les principaux avantages de cette architecture sont les suivants : -- you can store the **environment4d.json** file in a parent folder of your projects and decide not to commit it, allowing you to have your local component organization. -- if you want to use the same GitHub repository for several of your projects, you can reference it in the **environment4d.json** file and declare it in the **dependencies.json** file. +- vous pouvez stocker le fichier **environment4d.json** dans un dossier parent de vos projets et décider de ne pas le livrer (*commit*), ce qui vous permet d'avoir une organisation locale pour vos composants. +- si vous souhaitez utiliser le même dépôt GitHub pour plusieurs de vos projets, vous pouvez le référencer dans le fichier **environment4d.json** et le déclarer dans le fichier **dependencies.json**. -### Priority +### Priorité -Since components can be installed in different ways, a priority order is applied when the same component is referenced at several locations: +Puisque les composants peuvent être installés de différentes manières, un ordre de priorité est appliqué lorsque le même composant est référencé à plusieurs endroits : -**Higest priority** +**Priorité la plus élevée** -1. Components stored in the [**Components** folder of the project](architecture.md#components). -2. Components declared in the **dependencies.json** file (the **environment4d.json** declared path overrides the **dependencies.json** path to configure a local environment). -3. Internal User 4D components (e.g. 4D NetKit, 4D SVG...) +1. Composants stockés dans le [dossier **Components** du projet](architecture.md#components). +2. Composants déclarés dans le fichier **dependencies.json** (le chemin déclaré dans **environment4d.json** remplace le chemin **dependencies.json** pour configurer un environnement local). +3. Composants utilisateurs 4D internes (par exemple 4D NetKit, 4D SVG...) -**Lowest priority** +**Priorité la plus basse** ```mermaid flowchart TB - id1("1
Components from project's Components folder") + id1("1
Composants du dossier Components du projet") ~~~ - id2("2
Components listed in dependencies.json") - ~~~ - id2 -- environment4d.json gives path --> id4("Load component based on path declared in environment4d.json") + id2("2
Composants listés dans dependencies.json") + ~~ + id2 -- environment4d.json donne le chemin --> id4("Charger le composant basé sur le chemin déclaré dans environment4d.json") ~~~ - id3("3
User 4D components") - id2 -- environment4d.json doesn't give path --> id5("Load component next to package folder") + id3("3
Composants utilisateurs 4D internes") + id2 -- environment4d.json ne donne pas de chemin --> id5("Charger le composant à côté du dossier raciner") ~~~ - id3("3
User 4D components") + id3("3
Composants utilisateurs 4D internes") ``` -When a component cannot be loaded because of another instance of the same component located at a higher priority level, both get a specific [status](#dependency-status): the non-loaded component is given the *Overloaded* status, while the loaded component has the *Overloading* status. +Lorsqu'un composant ne peut pas être chargé à cause d'une autre instance du même composant située à un niveau de priorité plus élevé, les deux obtiennent un [statut](#dependency-status) spécifique : le composant non chargé reçoit le statut *Overloaded*, tandis que le composant chargé a le statut *Overloading*. -### Local components +### Composants locaux -You declare a local component in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant local dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -122,28 +122,28 @@ You declare a local component in the [**dependencies.json** file](#dependenciesj } ``` -... where "myComponent1" and "myComponent2" are the name of the components to be loaded. +... où "myComponent1" et "myComponent2" sont les noms des composants à charger. -By default, if "myComponent1" and "myComponent2" are not declared in an [**environment4d.json**](#environment4djson) file, 4D will look for the component's package folder (*i.e.* the project root folder of the component) at the same level as your 4D project's package folder, e.g.: +Par défaut, si "myComponent1" et "myComponent2" ne sont pas déclarés dans un fichier [**environment4d.json**](#environment4djson), 4D cherchera le dossier package du composant (c'est-à-dire le dossier racine du projet du composant) au même niveau que le dossier du package de votre projet 4D, par exemple : ``` /MyProjectRoot/ /MyProjectComponentRoot/ ``` -Thanks to this architecture, you can simply copy all your components at the same level as your projects and reference them in your **dependencies.json** files. +Grâce à cette architecture, vous pouvez simplement copier tous vos composants au même niveau que vos projets et les référencer dans vos fichiers **dependencies.json**. :::note -If you do not want to use the **dependencies.json** architecture, you can install local components by copying their files in the [**Components** folder of your project](architecture.md#components). +Si vous ne souhaitez pas utiliser l'architecture **dependencies.json**, vous pouvez installer des composants locaux en copiant leurs fichiers dans le [dossier **Components** de votre projet](architecture.md#components). ::: -#### Customizing component paths +#### Personnalisation des chemins des composants -If you want to customize the location of local components, you declare the paths for the dependencies that are not stored at the same level as the project folder in the [**environment4d.json**](#environment4djson) file. +Si vous souhaitez personnaliser l'emplacement des composants locaux, vous devez déclarer dans le fichier [**environment4d.json**](#environment4djson) les chemins des dépendances qui ne sont pas stockées au même niveau que le dossier projet. -You can use **relative** or **absolute** paths (see below). +Vous pouvez utiliser des chemins **relatifs** ou **absolus** (voir ci-dessous). Exemples : @@ -159,43 +159,43 @@ Exemples : :::note -If a component path declared in the **environment4d.json** file is not found when the project is started, the component is not loaded and gets the *Not found* [status](#dependency-status), even if a version of the component exists next to the project's package folder. +Si un chemin de composant déclaré dans le fichier **environment4d.json** n'est pas trouvé lorsque le projet est démarré, le composant n'est pas chargé et récupère le [statut](#dependency-status) *Not found*, même si une version du composant existe à côté du dossier racine du projet. ::: -#### Relative paths vs absolute paths +#### Chemins relatifs vs chemins absolus -Paths are expressed in POSIX syntax as described in [this paragraph](../Concepts/paths#posix-syntax). +Les chemins sont exprimés en syntaxe POSIX comme décrit dans [ce paragraphe](../Concepts/paths#posix-syntax). -Relative paths are relative to the [`environment4d.json`](#environment4djson) file. Absolute paths are linked to the user's machine. +Les chemins relatifs sont relatifs au fichier [`environment4d.json`](#environment4djson). Les chemins absolus sont liés à la machine de l'utilisateur. -Using relative paths is **recommended** in most cases, since they provide flexibility and portability of the components architecture, especially if the project is hosted in a source control tool. +L'utilisation de chemins relatifs est **recommandée** dans la plupart des cas, puisqu'ils fournissent flexibilité et portabilité de l'architecture des composants, surtout si le projet est hébergé dans un outil de contrôle de source. -Absolute paths should only be used for components that are specific to one machine and one user. +Les chemins absolus ne doivent être utilisés que pour les composants spécifiques à une machine et à un utilisateur. -### Components stored on GitHub +### Composants stockés sur GitHub -4D components available as GitHub releases can be referenced and automatically loaded and updated in your 4D projects. +Des composants 4D disponibles en tant que releases GitHub peuvent être référencés et automatiquement chargés et mis à jour dans vos projets 4D. :::note -Regarding components stored on GitHub, both [**dependencies.json**](#dependenciesjson) and [**environment4d.json**](#environment4djson) files support the same contents. +En ce qui concerne les composants stockés sur GitHub, les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson) prennent en charge le même contenu. ::: -#### Configuring the GitHub repository +#### Configuration du dépôt GitHub -To be able to directly reference and use a 4D component stored on GitHub, you need to configure the GitHub component's repository: +Pour pouvoir référencer et utiliser directement un composant 4D stocké sur GitHub, vous devez configurer le dépôt du composant GitHub : -- Compress the component files in ZIP format. -- Name this archive with the same name as the GitHub repository. -- Integrate the archive into a [GitHub release](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) of the repository. +- Compressez les fichiers des composants au format ZIP. +- Nommez cette archive avec le même nom que le dépôt GitHub. +- Intégrez l'archive dans une [release GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository) du dépôt. -These steps can easily be automated, with 4D code or using GitHub Actions, for example. +Ces étapes peuvent être facilement automatisées, avec du code 4D ou en utilisant des actions GitHub, par exemple. -#### Declaring paths +#### Déclaration des chemins -You declare a component stored on GitHub in the [**dependencies.json** file](#dependenciesjson) in the following way: +Vous déclarez un composant stocké sur GitHub dans le fichier [**dependencies.json** ](#dependenciesjson) de la manière suivante : ```json { @@ -208,7 +208,7 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -... where "myGitHubComponent1" is referenced and declared for the project, although "myGitHubComponent2" is only referenced. You need to declare it in the [**environment4d.json**](#environment4djson) file: +... où "myGitHubComponent1" est référencé et déclaré pour le projet, tandis que "myGitHubComponent2" est seulement référencé. Vous devez le déclarer dans le fichier [**environment4d.json**](#environment4djson) : ```json { @@ -220,19 +220,19 @@ You declare a component stored on GitHub in the [**dependencies.json** file](#de } ``` -"myGitHubComponent2" can be used by several projects. +"myGitHubComponent2" peut être utilisé par plusieurs projets. -#### Tags and versions +#### Tags et versions -When a release is created in GitHub, it is associated to a **tag** and a **version**. The Dependency manager uses these information to handle automatic availability of components. +Lorsqu'une release est créée dans GitHub, elle est associée à un **tag** et à une **version**. Le gestionnaire de dépendances utilise ces informations pour gérer la disponibilité automatique des composants. :::note -If you select the [**Follow 4D Version**](#defining-a-github-dependency-version-range) dependency rule, you need to use a [specific naming convention for the tags](#naming-conventions-for-4d-version-tags). +Si vous sélectionnez la règle de dépendance [**Suivre la version 4D**](#defining-a-github-dependency-version-range), vous devez utiliser une [convention de nommage spécifique pour les tags](#naming-conventions-for-4d-version-tags). ::: -- **Tags** are texts that uniquely reference a release. In the [**dependencies.json** file](#dependenciesjson) and [**environment4d.json**](#environment4djson) files, you can indicate the release tag you want to use in your project. For example : +- Les **Tags** sont des textes qui référencent de manière unique une release. Dans les fichiers [**dependencies.json**](#dependenciesjson) et [**environment4d.json**](#environment4djson), vous pouvez indiquer le release tag que vous souhaitez utiliser dans votre projet. Par exemple : ```json { @@ -245,7 +245,7 @@ If you select the [**Follow 4D Version**](#defining-a-github-dependency-version- } ``` -- A release is also identified by a **version**. The versioning system used is based on the [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/) concept, which is the most commonly used. Each version number is identified as follows: `majorNumber.minorNumber.pathNumber`. In the same way as for tags, you can indicate the version of the component you wish to use in your project, as in this example: +- Une release est également identifiée par une **version**. Le système de versionnement utilisé est basé sur le concept de [*Semantic Versioning*](https://regex101.com/r/Ly7O1x/3/), qui est le plus couramment utilisé. Chaque numéro de version est identifié comme suit : `majorNumber.minorNumber.pathNumber`. De la même manière que pour les tags, vous pouvez indiquer la version du composant que vous souhaitez utiliser dans votre projet, comme dans cet exemple : ```json { @@ -258,149 +258,149 @@ If you select the [**Follow 4D Version**](#defining-a-github-dependency-version- } ``` -A range is defined by two semantic versions, a min and a max, with operators '\< | > | >= | <= | ='. The `*` can be used as a placeholder for all versions. ~ and ^ prefixes define versions starting at a number, and up to respectively the next major and minor version. +Un intervalle est défini par deux versions sémantiques, un minimum et un maximum, avec les opérateurs "\< | > | >= | <= | =". Le `*` peut être utilisé comme substitut pour toutes les versions. Les préfixes ~ et ^ définissent les versions à partir d'un numéro, et jusqu'à respectivement la version majeure et mineure suivante. -Here are a few examples: +Voici quelques exemples : -- "latest": the version having the “latest” badge in GitHub releases. -- "\*": the latest version released. -- "1.\*": all version of major version 1. -- "1.2.\*": all patches of minor version 1.2. -- ">=1.2.3": the latest version, starting with the 1.2.3 version. -- ">1.2.3": the latest version, starting with the version just after the 1.2.3. -- "^1.2.3": the latest version 1, starting with the 1.2.3 version and strictly lower than version 2. -- "~1.2.3": the latest version 1.2, starting with the 1.2.3 version and strictly lower than version 1.3. -- "<=1.2.3": the latest version until the 1.2.3 one. -- "1.0.0 – 1.2.3" or ">=1.0.0 <=1.2.3": version between 1.0.0 and 1.2.3. -- "`<1.2.3 || >=2`": version that is not between 1.2.3 and 2.0.0. +- "latest" : la version ayant le badge "latest" dans les releases GitHub. +- "\*" : la dernière version publiée. +- "1.\*" : toutes les versions de la version majeure 1. +- "1.2.\*" : tous les correctifs de la version mineure 1.2. +- ">=1.2.3" : la dernière version, à partir de la version 1.2.3. +- ">1.2.3" : la dernière version, en commençant par la version juste après la 1.2.3. +- "^1.2.3" : la dernière version 1, à partir de la version 1.2.3 et strictement inférieure à la version 2. +- "~1.2.3" : la dernière version 1.2, à partir de la version 1.2.3 et strictement inférieure à la version 1.3. +- "<=1.2.3" : la dernière version jusqu'à la 1.2.3. +- "1.0.0 - 1.2.3" ou ">=1.0.0 <=1.2.3" : version comprise entre 1.0.0 et 1.2.3. +- "`<1.2.3 || >=2`" : version qui n'est pas comprise entre 1.2.3 et 2.0.0. -If you do not specify a tag or a version, 4D automatically retrieves the "latest" version. +Si vous ne spécifiez pas de tag ou de version, 4D récupère automatiquement la version "latest". -The Dependency manager checks periodically if component updates are available on Github. If a new version is available for a component, an update indicator is then displayed for the component in the dependency list, [depending on your settings](#defining-a-github-dependency-version-range). +Le Gestionnaire de dépendances vérifie périodiquement si des mises à jour de composants sont disponibles sur Github. Si une nouvelle version est disponible pour un composant, un indicateur de mise à jour est alors affiché pour le composant dans la liste des dépendances, [en fonction de vos paramètres](#defining-a-github-dependency-version-range). -#### Naming conventions for 4D version tags +#### Conventions de nommage pour les tags de version 4D -If you want to use the [**Follow 4D Version**](#defining-a-github-dependency-version-range) dependency rule, the tags for component releases on the Github repository must comply with specific conventions. +Si vous souhaitez utiliser la règle de dépendance [**Suivre la version 4D**](#defining-a-github-dependency-version-range), les tags des releases des composants sur le dépôt Github doivent respecter des conventions spécifiques. -- **LTS versions**: `x.y.p` pattern, where `x.y` corresponds to the main 4D version to follow and `p` (optional) can be used for patch versions or additional updates. When a project specifies that it follows the 4D version for *x.y* LTS version, the Dependency Manager will resolve it as "the latest version x.\*" if available or "version below x". If no such version exists, the user will be notified. For example, "20.4" will be resolved by the Dependency manager as "the latest component version 20.\* or version below 20". +- **Versions LTS** : Modèle `x.y.p`, où `x.y` correspond à la version principale de 4D à suivre et `p` (facultatif) peut être utilisé pour les versions correctives ou les mises à jour supplémentaires. Lorsqu'un projet spécifie qu'il suit la version 4D pour la version LTS *x.y*, le Gestionnaire de dépendances le résoudra comme "la dernière version x.\*" si elle est disponible ou "une version inférieure à x". Si une telle version n'existe pas, l'utilisateur en sera informé. Par exemple, "20.4" sera résolu par le Gestionnaire de dépendances comme "la dernière version du composant 20.\* ou une version inférieure à 20". -- **R-Release versions**: `xRy.p` pattern, where `x` and `y` correspond to the main 4D R-release version to follow and `p` (optional) can be used for patch versions or additional updates. When a project specifies that it follows the 4D version for *xRy* version, the Dependency Manager will resolve it to the "latest version below xR(y+1)" if available. If no such version exists, the user will be notified. For example, "20R9" will be resolved by the Dependency manager as "the latest component version below 20R10". +- **Versions R-Release** : Modèle `xRy.p`, où `x` et `y` correspondent à la version principale de 4D R à suivre et `p` (facultatif) peut être utilisé pour les versions correctives ou les mises à jour supplémentaires. Lorsqu'un projet spécifie qu'il suit la version 4D pour la version *xRy*, le Gestionnaire de dépendances le résoudra à la "dernière version inférieure à xR(y+1)" si elle est disponible. Si une telle version n'existe pas, l'utilisateur en sera informé. Par exemple, "20R9" sera résolu par le gestionnaire de dépendances comme "la dernière version du composant inférieure à 20R10". :::note -The component developer can define a minimum 4D version in the component's [`info.plist`](../Extensions/develop-components.md#infoplist) file. +Le développeur du composant peut définir une version 4D minimale dans le fichier [`info.plist`](../Extensions/develop-components.md#infoplist) du composant. ::: -#### Private repositories +#### Dépôts privés -If you want to integrate a component located in a private repository, you need to tell 4D to use a connection token to access it. +Si vous souhaitez intégrer un composant situé dans un référentiel privé, vous devez indiquer à 4D d'utiliser un token (*jeton*) de connexion pour y accéder. -To do this, in your GitHub account, create a **classic** token with access rights to **repo**. +Pour cela, dans votre compte GitHub, créez un token **classic** avec les droits d'accès au **dépôt**. :::note -For more information, please refer to the [GitHub token interface](https://github.com/settings/tokens). +Pour plus d'informations, veuillez vous référer à [GitHub token interface](https://github.com/settings/tokens). ::: -You then need to [provide your connection token](#providing-your-github-access-token) to the Dependency manager. +Vous devez ensuite [fournir votre token de connexion](#providing-your-github-access-token) au Gestionnaire de dépendances. -#### Local cache for dependencies +#### Cache local pour les dépendances -Referenced GitHub components are downloaded in a local cache folder then loaded in your environment. The local cache folder is stored at the following location: +Les composants GitHub référencés sont téléchargés dans un dossier de cache local puis chargés dans votre environnement. Le dossier de cache local est stocké à l'emplacement suivant : -- on macOs: `$HOME/Library/Caches//Dependencies` -- on Windows: `C:\Users\\AppData\Local\\Dependencies` +- sous macOs : `$HOME/Library/Caches//Dependencies` +- sous Windows : `C:\Users\\AppData\Local\\Dependencies` -...where `` can be "4D", "4D Server", or "tool4D". +...où `` peut être "4D", "4D Server" ou "tool4D". ### dependency-lock.json -A `dependency-lock.json` file is created in the [`userPreferences` folder](architecture.md#userpreferencesusername) of your project. +Un fichier `dependency-lock.json` est créé dans le dossier [`userPreferences`](architecture.md#userpreferencesusername) de votre projet. -This file logs information such as the state of dependencies, paths, urls, loading errors, as well as other information. It could be useful for component loading management or troubleshooting. +Ce fichier enregistre des informations telles que le statut des dépendances, les chemins d'accès, les Url, les erreurs de chargement, ainsi que d'autres informations. Il peut être utile pour la gestion du chargement de composants ou le dépannage. -## Monitoring Project Dependencies +## Suivi des dépendances du projet -In an opened project, you can add, remove, update, and get information about dependencies and their current loading status in the **Dependencies** panel. +Dans un projet ouvert, vous pouvez ajouter, supprimer, mettre à jour et obtenir des informations sur les dépendances et leur statut courant de chargement dans la fenêtre **Dépendances**. -To display the Dependencies panel: +Pour afficher la fenêtre Dépendances : -- with 4D, select the **Design/Project Dependencies** menu item (Development environment),
+- avec 4D, sélectionnez la ligne de menu **Développement/Dépendances du projet** (environnement de développement),
![dependency-menu](../assets/en/Project/dependency-menu.png) - with 4D Server, select the **Window/Project Dependencies** menu item.
![dependency-menu-server](../assets/en/Project/dependency-menu-server.png) -The Dependencies panel is then displayed. Dependencies are sorted by name in alphabetical order: +La fenêtre Dépendances s'affiche alors. Les dépendances sont classées par nom par ordre alphabétique : ![dependency](../assets/en/Project/dependency.png) -The Dependencies panel interface allows you to manage dependencies (on 4D single-user and 4D Server). +L'interface de la fenêtre Dépendances vous permet de gérer les dépendances (sur 4D monoposte et 4D Server). -### Filtering dependencies +### Filtrer les dépendances -By default, all dependencies identified by the Dependency manager are listed, whatever their [status](#dependency-status). You can filter the displayed dependencies according to their status by selecting the appropriate tab at the top of the Dependencies panel: +Par défaut, toutes les dépendances identifiées par le Gestionnaire de dépendances sont listées, quel que soit leur [statut](#dependency-status). Vous pouvez filtrer les dépendances affichées en fonction de leur statut en sélectionnant l'onglet approprié en haut de la fenêtre : ![dependency-tabs](../assets/en/Project/dependency-tabs.png) -- **Active**: Dependencies that are loaded and can be used in the project. It includes *overloading* dependencies, which are actually loaded. *Overloaded* dependencies are listed in the **Conflicts** panel, along with all conflicting dependencies. -- **Inactive**: Dependencies that are not loaded in the project and are not available. There are many possible reasons for this status: missing files, version incompatibility... -- **Conflict**: Dependencies that are loaded but that overloads at least one other dependency at lower [priority level](#priority). Overloaded dependencies are also displayed so that you can check the origin of the conflict and take appropriate actions. +- **Actifs** : Dépendances chargées et utilisables dans le projet. Il comprend des dépendances *overloading*, qui sont effectivement chargées. Les dépendances *overloaded* sont listées dans l'onglet **Conflits**, ainsi que toutes les dépendances conflictuelles. +- **Inactifs** : Dépendances qui ne sont pas chargées dans le projet et qui ne sont pas disponibles. Diverses raisons peuvent expliquer ce statut : fichiers manquants, incompatibilité de version... +- **Conflit** : Dépendances qui sont chargées mais qui surchargent au moins une autre dépendance à un [niveau de priorité](#priority) inférieur. Les dépendances surchargées sont également affichées afin que vous puissiez vérifier l'origine du conflit et prendre les mesures appropriées. -### Dependency status +### Statut des dépendances -Dependencies requiring the developer's attention are indicated by a **status label** at the right side of the line and a specific background color: +Les dépendances nécessitant l'attention du développeur sont signalées par une **étiquette de statut** à droite de la ligne et une couleur de fond spécifique : ![dependency-status](../assets/en/Project/dependency-conflict2.png) -The following status labels are available: +Les étiquettes de statut suivantes sont disponibles : -- **Overloaded**: The dependency is not loaded because it is overloaded by another dependency with the same name at a higher [priority level](#priority). -- **Overloading**: The dependency is loaded and is overloading one or more other dependencies with the same name at a lower [priority level](#priority). -- **Not found**: The dependency is declared in the dependencies.json file but is not found. -- **Inactive**: The dependency is not loaded because it is not compatible with the project (e.g. the component is not compiled for the current platform). -- **Duplicated**: The dependency is not loaded because another dependency with the same name exists at the same location (and is loaded). -- **Available after restart**: The dependency reference has just been added or updated [using the interface](#monitoring-project-dependencies), it will be loaded once the application restarts. -- **Unloaded after restart**: The dependency reference has just been removed [using the interface](#removing-a-dependency), it will be unloaded once the application restarts. -- **Update available \**: A new version of the GitHub dependency matching your [component version configuration](#defining-a-github-dependency-version-range) has been detected. -- **Refreshed after restart**: The [component version configuration](#defining-a-github-dependency-version-range) of the GitHub dependency has been modified, it will be adjusted the next startup. -- **Recent update**: A new version of the GitHub dependency has been loaded at startup. +- **Overloaded** : La dépendance n'est pas chargée car elle est surchargée par une autre dépendance portant le même nom et ayant un [niveau de priorité](#priority) plus élevé. +- **Overloading** : La dépendance est chargée et surcharge une ou plusieurs autres dépendances avec le même nom à un [niveau de priorité](#priority) inférieur. +- **Non trouvé** : La dépendance est déclarée dans le fichier dependencies.json mais n'est pas trouvée. +- **Inactif** : La dépendance n'est pas chargée car elle n'est pas compatible avec le projet (par exemple, le composant n'est pas compilé pour la plate-forme actuelle). +- **Dupliqué** : La dépendance n'est pas chargée car une autre dépendance portant le même nom existe au même endroit (et est chargée). +- **Disponible après redémarrage** : La référence de la dépendance vient d'être ajoutée ou mise à jour [à l'aide de l'interface](#monitoring-project-dependencies), elle sera chargée une fois que l'application aura redémarré. +- **Déchargé après redémarrage** : La référence à la dépendance vient d'être supprimée [en utilisant l'interface](#removing-a-dependency), elle sera déchargée une fois que l'application aura redémarré. +- **Mise à jour disponible \** : Une nouvelle version de la dépendance GitHub correspondant à votre [configuration de version du composant](#defining-a-github-dependency-version-range) a été détectée. +- **Actualisé après redémarrage** : La [configuration de version](#defining-a-github-dependency-version-range) de la dépendance GitHub a été modifiée, elle sera ajustée au prochain démarrage. +- **Mise à jour récente** : Une nouvelle version de la dépendance GitHub a été chargée au démarrage. -A tooltip is displayed when you hover over the dependency line, provding additional information about the status: +Une infobulle s'affiche lorsque vous survolez la ligne de dépendance, fournissant des informations supplémentaires sur le statut : ![dependency-tips](../assets/en/Project/dependency-tip1.png) -### Dependency origin +### Origine de la dépendance -The Dependencies panel lists all project dependencies, whatever their origin, i.e. wherever they come from. The dependency origin is provided by the tag under its name: +Le panneau Dépendances liste toutes les dépendances du projet, quelle que soit leur origine, c'est-à-dire d'où qu'elles viennent. L'origine de la dépendance est fournie par l'étiquette sous son nom : ![dependency-origin](../assets/en/Project/dependency-origin.png) -The following origins are possible: +Les options suivantes sont disponibles : -| Origin tag | Description | +| Étiquette d'origine | Description | | --------------------------------- | ------------------------------------------------------------------------------ | -| 4D Component | Built-in 4D component, stored in the `Components` folder of the 4D application | -| dependencies.json | Component declared in the [`dependencies.json`](#dependenciesjson) file | -| Environment | Component declared in the [`environnement4d.json`](#environment4djson) file | -| Project Component | Component located in the [`Components`](architecture.md#components) folder | +| Composant 4D | Composant 4D intégré, stocké dans le dossier `Components` de l'application 4D | +| dependencies.json | Composant déclaré dans le fichier [`dependencies.json`](#dependenciesjson) | +| Environnement | Composant déclaré dans le fichier [`environnement4d.json`](#environment4djson) | +| Composant du projet | Composant situé dans le dossier [`Components`](architecture.md#components) | -**Right-click** in a dependency line and select **Show on disk** to reveal the location of a dependency: +**Cliquez avec le bouton droit de la souris** dans une ligne de dépendance et sélectionnez **Afficher sur le disque** pour révéler l'emplacement d'une dépendance : ![dependency-show](../assets/en/Project/dependency-show.png) :::note -This item is not displayed if the dependency is inactive because its files are not found. +Cet élément n'est pas affiché si la dépendance est inactive parce que ses fichiers sont introuvables. ::: -Component icon and location logo provide additional information: +L'icône du composant et le logo de l'emplacement fournissent des informations supplémentaires : -- The component logo indicates if it is provided by 4D or a third-party developer. -- Local components can be differentiated from GitHub components by a small icon. +- Le logo du composant indique s'il est fourni par 4D ou par un développeur tiers. +- Les composants locaux peuvent être différenciés des composants GitHub par une petite icône. ![dependency-origin](../assets/en/Project/dependency-github.png) diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$attributes.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$attributes.md index d5210c3aa0ea91..68e3e192e83f70 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$attributes.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$attributes.md @@ -3,11 +3,11 @@ id: attributes title: $attributes --- -Allows selecting the attribute(s) to get from the dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, or `Employee?$attributes=employer.name`). +Permet de sélectionner le ou les attribut(s) à obtenir de la dataclass (*e.g.*, `Company(1)?$attributes=name,city`, `Company(1)?$attributes=employees.lastname`, ou `Employee?$attributes=employer.name`). ## Description -If you have relation attributes in a dataclass, use `$attributes` to define the path of attributes whose values you want to get for the related entity or entities. +Lorsque vous avez des attributs relationnels dans une dataclass, utilisez `$attributes` pour définir le chemin des attributs dont vous souhaitez obtenir les valeurs pour l'entité ou les entités associée(s). Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) ou à une entity selection (par exemple, People/$entityset/0AF4679A5C394746BFEB68D2162A19FF). @@ -22,8 +22,8 @@ Vous pouvez appliquer des `$attributes` à une entité (par exemple, People (1)) - `$attributes=relatedEntities.*` : toutes les propriétés des entités liées sont retournées - `$attributes=relatedEntities.attributePath1, relatedEntity.attributePath2, ...` : seuls ces attributs des entités liées sont retournés. -- If `$attributes` is specified for **storage** attributes: - - `$attributes=attribute1, attribute2, ...`: only those attributes of the entities are returned. +- Si `$attributes` est spécifié pour les attributs **storage** : + - `$attributes=attribute1, attribute2, ...` : seuls les attributs des entités sont renvoyés. ## Exemple avec plusieurs entités liées diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md index 3e5da3f941b00f..2a3fac86364d9c 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md @@ -36,7 +36,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, **Réponse** : -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Chaîne, vou **Réponse** : -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Si vous souhaitez obtenir un calcul avec un attribut, vous pouvez écrire ce qui **Réponse** : -`235000` +`335000` Si vous souhaitez effectuer un calcul avec un attribut Objet, vous pouvez saisir ce qui suit : diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md index 5bb8d35e484ec0..f77757f2750316 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Un développeur 4D peut facilement implémenter ces palettes dans leur applicati La documentation principale de l'[interface 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se trouve dans le *4D - Mode Développement*. -Vous trouverez ci-dessous la documentation de configuration de l'Assistant de table. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Assistant de table @@ -294,4 +297,114 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### Voir également -[4D Write Pro - Table Wizard (vidéo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (vidéo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Historique + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png differ diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/code-editor/write-class-method.md b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/code-editor/write-class-method.md index 96d46eb142d084..3513373fd38a40 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/code-editor/write-class-method.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20-R9/code-editor/write-class-method.md @@ -15,7 +15,7 @@ L'éditeur de code 4D fournit un contrôle de base des erreurs de syntaxe. Un co :::note -If you are used to coding with **VS Code**, you can also use this editor with 4D code after installing the [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode) extension. +Si vous avez l'habitude de coder avec **VS Code**, vous pouvez également utiliser cet éditeur avec le Langage 4D après avoir installé l'extension [4D-Analyzer](https://github.com/4d/4D-Analyzer-VSCode). ::: @@ -33,7 +33,7 @@ Chaque fenêtre de l'éditeur de code dispose d'une barre d'outils qui permet un | **Déployer tout / Contracter tout** | ![expand-collapse-button](../assets/en/code-editor/expand-collapse-all.png) | Ces boutons permettent de déployer ou de contracter toutes les structures de flux de contrôle du code. | | **Informations sur la méthode** | ![method-information-icon](../assets/en/code-editor/method-information.png) | Affiche la boîte de dialogue [Propriétés de la méthode](../Project/code-overview.md#project-method-properties) (méthodes de projet uniquement). | | **Dernières valeurs du presse-papiers** | ![last-clipboard-values-icon](../assets/en/code-editor/last-clipboard-values.png) | Affiche les dernières valeurs stockées dans le presse-papiers. | -| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. You can [use these clipboards](#clipboards) by clicking on them directly or by using keyboard shortcuts. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | +| **Presse-papiers** | ![clipboard icons](../assets/en/code-editor/clipboards.png) | Neuf presse-papiers sont disponibles dans l'éditeur de code. Vous pouvez [utiliser ces presse-papiers](#clipboards) en cliquant directement dessus ou en utilisant des raccourcis clavier. Vous pouvez utiliser l'[option Préférences](Preferences/methods.md#options-1) pour les masquer. | | **Menu déroulant de navigation** | ![code-navigation-icons](../assets/en/code-editor/tags.png) | Vous permet de naviguer à l'intérieur des méthodes et des classes avec du contenu étiqueté automatiquement ou des marqueurs déclarés manuellement. Voir ci-dessous | ### Zone d'édition @@ -368,7 +368,7 @@ La liste est par ordre alphabétique. Choisissez la valeur en double-cliquant de Par défaut, vous pouvez également insérer une valeur suggérée en appuyant sur l'un des délimiteurs suivants `( ; : = < [ {` après avoir sélectionné une valeur : la valeur insérée est ensuite suivie du délimiteur, prête pour la saisie des données. -![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** key --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) +![](../assets/en/code-editor/autocomplete-delimiter.png) + **(** touche --> ![](../assets/en/code-editor/autocomplete-delimiter-2.png) > Vous pouvez désactiver l'utilisation de délimiteurs pour insérer des valeurs suggérées dans les **Préférences** > **Méthodes** > **Options**. diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20/API/CollectionClass.md b/i18n/fr/docusaurus-plugin-content-docs/version-20/API/CollectionClass.md index 4f45f780f6f457..ed182ec021d931 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20/API/CollectionClass.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20/API/CollectionClass.md @@ -249,7 +249,7 @@ Contrairement aux collections standard (non partagées), les collections partag | Paramètres | Type | | Description | | ---------- | ------- |:--:| ------------------------------------------------ | -| index | Integer | -> | Index de l'élément à renvoyer | +| index | Integer | -> | Indice de l'élément à renvoyer | | Résultat | any | <- | L'élément à cet index| diff --git a/i18n/fr/docusaurus-plugin-content-docs/version-20/REST/$compute.md b/i18n/fr/docusaurus-plugin-content-docs/version-20/REST/$compute.md index d6da37af49a22c..d63061d2e5b07d 100644 --- a/i18n/fr/docusaurus-plugin-content-docs/version-20/REST/$compute.md +++ b/i18n/fr/docusaurus-plugin-content-docs/version-20/REST/$compute.md @@ -38,8 +38,7 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, `GET /rest/Employee/salary/?$compute=$all` **Réponse** : - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Si vous souhaitez obtenir tous les calculs pour un attribut de type Numérique, } ```` -Si vous souhaitez obtenir tous les calculs pour un attribut de type Chaîne, vous pouvez écrire : +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Réponse** : +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Si vous souhaitez obtenir un calcul avec un attribut, vous pouvez écrire ce qui **Réponse** : -`235000` +`335000` Si vous souhaitez effectuer un calcul avec un attribut Objet, vous pouvez saisir ce qui suit : diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/Notes/updates.md b/i18n/ja/docusaurus-plugin-content-docs/current/Notes/updates.md index 9fc6b706539598..f300f784014171 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/current/Notes/updates.md +++ b/i18n/ja/docusaurus-plugin-content-docs/current/Notes/updates.md @@ -28,6 +28,7 @@ Read [**What’s new in 4D 20 R10**](https://blog.4d.com/en-whats-new-in-4d-20-R - 新しい[4D AIKit コンポーネント](../aikit/overview.md) を使用することでサードパーティAI のAPI とやり取りをすることが可能になります。 - 以下のVP コマンドのコールバックは、4D カスタム関数がその計算を全て終えるのを待つようになりました: [VP IMPORT DOCUMENT](../ViewPro/commands/vp-import-document.md), [VP IMPORT FORM BLOB](../ViewPro/commands/vp-import-from-blob.md)、[VP IMPORT FROM OBJECT](../ViewPro/commands/vp-import-from-object.md)、および [VP FLUSH COMMANDS](../ViewPro/commands/vp-flush-commands.md) - Google およびMicrosoft 365 カレンダーを管理するための新しい[4D Netkit](https://developer.4d.com/4D-NetKit/) 機能。OAuth 2.0 認証のためのホストWeb サーバーを使用する機能。 +- 4D Write Pro Interface: New [integrated AI](../WritePro/writeprointerface.md#integrated-ai) to interact with **chatGTP** from your 4D Write Pro documents. - [**Fixed bug list**](https://bugs.4d.fr/fixedbugslist?version=20_R9): list of all bugs that have been fixed in 4D 20 R9. ## 4D 20 R8 diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/REST/$compute.md b/i18n/ja/docusaurus-plugin-content-docs/current/REST/$compute.md index 0612d97fdbd1ea..58b8adc3a5085c 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/current/REST/$compute.md +++ b/i18n/ja/docusaurus-plugin-content-docs/current/REST/$compute.md @@ -36,7 +36,7 @@ title: $compute **レスポンス**: -``` +```js { "salary": { "count": 4, @@ -54,7 +54,7 @@ title: $compute **レスポンス**: -``` +```js { "salary": { "count": 4, @@ -70,7 +70,7 @@ title: $compute **レスポンス**: -`235000` +`335000` オブジェクト属性に対して特定の計算のみをおこなうには、次のように書きます: diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md b/i18n/ja/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md index 34609c667b20ef..0207b69ff7022f 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md +++ b/i18n/ja/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ title: 4D WritePro インターフェース インターフェースのマニュアルについては、*4D デザインリファレンス* の [4D Write Pro エリアのドキュメント](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.ja.html) を参照ください。 -表ウィザードの設定に関するドキュメントは以下のとおりです。 +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## 表ウィザード @@ -297,4 +300,114 @@ JSONファイルで設定する各属性に対して、以下の WP属性を定 #### 参照 -[4D Write Pro - 表ウィザード (チュートリアル動画)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - 表ウィザード (チュートリアル動画)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### 履歴 + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-19/REST/$compute.md b/i18n/ja/docusaurus-plugin-content-docs/version-19/REST/$compute.md index 1262c031ff5a3c..695d38de9e6cf6 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/version-19/REST/$compute.md +++ b/i18n/ja/docusaurus-plugin-content-docs/version-19/REST/$compute.md @@ -38,8 +38,7 @@ title: '$compute' `GET /rest/Employee/salary/?$compute=$all` **レスポンス**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ title: '$compute' } ```` -文字列型の属性を対象にすべての計算値を取得するには、次のように書きます: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**レスポンス**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ title: '$compute' **レスポンス**: -`235000` +`335000` オブジェクト属性に対して特定の計算のみをおこなうには、次のように書きます: diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md b/i18n/ja/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md index 0612d97fdbd1ea..acd13b662a4145 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md +++ b/i18n/ja/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md @@ -36,7 +36,7 @@ title: $compute **レスポンス**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ title: $compute **レスポンス**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ title: $compute **レスポンス**: -`235000` +`335000` オブジェクト属性に対して特定の計算のみをおこなうには、次のように書きます: diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md index 0612d97fdbd1ea..acd13b662a4145 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md +++ b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md @@ -36,7 +36,7 @@ title: $compute **レスポンス**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ title: $compute **レスポンス**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ title: $compute **レスポンス**: -`235000` +`335000` オブジェクト属性に対して特定の計算のみをおこなうには、次のように書きます: diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md index 34609c667b20ef..0207b69ff7022f 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md +++ b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ title: 4D WritePro インターフェース インターフェースのマニュアルについては、*4D デザインリファレンス* の [4D Write Pro エリアのドキュメント](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.ja.html) を参照ください。 -表ウィザードの設定に関するドキュメントは以下のとおりです。 +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## 表ウィザード @@ -297,4 +300,114 @@ JSONファイルで設定する各属性に対して、以下の WP属性を定 #### 参照 -[4D Write Pro - 表ウィザード (チュートリアル動画)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - 表ウィザード (チュートリアル動画)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### 履歴 + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/ja/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png differ diff --git a/i18n/ja/docusaurus-plugin-content-docs/version-20/REST/$compute.md b/i18n/ja/docusaurus-plugin-content-docs/version-20/REST/$compute.md index 1262c031ff5a3c..695d38de9e6cf6 100644 --- a/i18n/ja/docusaurus-plugin-content-docs/version-20/REST/$compute.md +++ b/i18n/ja/docusaurus-plugin-content-docs/version-20/REST/$compute.md @@ -38,8 +38,7 @@ title: '$compute' `GET /rest/Employee/salary/?$compute=$all` **レスポンス**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ title: '$compute' } ```` -文字列型の属性を対象にすべての計算値を取得するには、次のように書きます: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**レスポンス**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ title: '$compute' **レスポンス**: -`235000` +`335000` オブジェクト属性に対して特定の計算のみをおこなうには、次のように書きます: diff --git a/i18n/pt/docusaurus-plugin-content-docs/current.json b/i18n/pt/docusaurus-plugin-content-docs/current.json index b0f4fdb9e941dc..8648b55185b57a 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/current.json +++ b/i18n/pt/docusaurus-plugin-content-docs/current.json @@ -624,7 +624,7 @@ "description": "The label for category Mail in sidebar docs" }, "sidebar.docs.category.Math": { - "message": "Math", + "message": "Funções matemáticas", "description": "The label for category Math in sidebar docs" }, "sidebar.docs.category.Messages": { @@ -940,7 +940,7 @@ "description": "The generated-index page title for category Mail in sidebar docs" }, "sidebar.docs.category.Math.link.generated-index.title": { - "message": "Math", + "message": "Funções matemáticas", "description": "The generated-index page title for category Math in sidebar docs" }, "sidebar.docs.category.Menus.link.generated-index.title": { diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/Notes/updates.md b/i18n/pt/docusaurus-plugin-content-docs/current/Notes/updates.md index 63cbce2df787d2..b35dd1fb092b40 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/current/Notes/updates.md +++ b/i18n/pt/docusaurus-plugin-content-docs/current/Notes/updates.md @@ -28,6 +28,7 @@ Read [**What’s new in 4D 20 R9**](https://blog.4d.com/en-whats-new-in-4d-20-R9 - New [4D AIKit component](../aikit/overview.md) enabling interaction with third-party AI APIs. - The following VP command callbacks now wait for all 4D custom functions to complete their calculations: [VP IMPORT DOCUMENT](../ViewPro/commands/vp-import-document.md), [VP IMPORT FORM BLOB](../ViewPro/commands/vp-import-from-blob.md), [VP IMPORT FROM OBJECT](../ViewPro/commands/vp-import-from-object.md), and [VP FLUSH COMMANDS](../ViewPro/commands/vp-flush-commands.md). - New [4D Netkit](https://developer.4d.com/4D-NetKit/) features to manage Google and Microsoft 365 calendars; ability to use the host web server for OAuth 2.0 authentication. +- 4D Write Pro Interface: New [integrated AI](../WritePro/writeprointerface.md#integrated-ai) to interact with **chatGTP** from your 4D Write Pro documents. - [**Fixed bug list**](https://bugs.4d.fr/fixedbugslist?version=20_R9): list of all bugs that have been fixed in 4D 20 R9. ## 4D 20 R8 diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/REST/$compute.md b/i18n/pt/docusaurus-plugin-content-docs/current/REST/$compute.md index 171b5fe4c106b5..b5d843780e4651 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/current/REST/$compute.md +++ b/i18n/pt/docusaurus-plugin-content-docs/current/REST/$compute.md @@ -36,7 +36,7 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev **Response**: -``` +```js { "salary": { "count": 4, @@ -54,7 +54,7 @@ Se quiser obter todos os cálculos para um atributo do tipo String, pode escreve **Response**: -``` +```js { "salary": { "count": 4, @@ -70,7 +70,7 @@ Se pretender obter apenas um cálculo num atributo, pode escrever o seguinte: **Response**: -`235000` +`335000` Se pretender efetuar um cálculo num atributo de um objeto, pode escrever o seguinte: diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md b/i18n/pt/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md index b26a54e6c1392c..fe17397fdf0290 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md +++ b/i18n/pt/docusaurus-plugin-content-docs/current/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Um desenvolvedor 4D pode facilmente implementar essas paletas em sua aplicação La documentación principal de [la interfaz de 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se encuentra en el manual *Diseño 4D*. -Você encontrará abaixo a documentação de configuração do Assistente de tabelas. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Assistente de tabelas @@ -294,4 +297,114 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### Veja também -[4D Write Pro - Table Wizard (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Histórico + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-button.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/current/assets/en/WritePro/ai-send.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/current/commands/theme/Math.md b/i18n/pt/docusaurus-plugin-content-docs/current/commands/theme/Math.md index 50ea4c931c579a..7fbba2beccc329 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/current/commands/theme/Math.md +++ b/i18n/pt/docusaurus-plugin-content-docs/current/commands/theme/Math.md @@ -1,6 +1,6 @@ --- id: Math_theme -title: Math +title: Funções matemáticas slug: /commands/theme/Math --- diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-19/REST/$compute.md b/i18n/pt/docusaurus-plugin-content-docs/version-19/REST/$compute.md index d8a49053699667..32fd09ee6847b9 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-19/REST/$compute.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-19/REST/$compute.md @@ -38,8 +38,7 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev `GET /rest/Employee/salary/?$compute=$all` **Resposta**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev } ```` -Se quiser obter todos os cálculos para um atributo do tipo String, pode escrever: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Resposta**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Se pretender obter apenas um cálculo num atributo, pode escrever o seguinte: **Resposta**: -`235000` +`335000` Se pretender efetuar um cálculo num atributo de um objeto, pode escrever o seguinte: diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8.json b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8.json index 0309d81c2a72dd..6681fc9edf5d8a 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8.json +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8.json @@ -320,11 +320,11 @@ "description": "The generated-index page title for category Mail in sidebar docs" }, "sidebar.docs.category.Math": { - "message": "Math", + "message": "Funções matemáticas", "description": "The label for category Math in sidebar docs" }, "sidebar.docs.category.Math.link.generated-index.title": { - "message": "Math", + "message": "Funções matemáticas", "description": "The generated-index page title for category Math in sidebar docs" }, "sidebar.docs.category.Menus": { diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md index 171b5fe4c106b5..6d45ae02d16f54 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/REST/$compute.md @@ -36,7 +36,7 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev **Response**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Se quiser obter todos os cálculos para um atributo do tipo String, pode escreve **Response**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Se pretender obter apenas um cálculo num atributo, pode escrever o seguinte: **Response**: -`235000` +`335000` Se pretender efetuar um cálculo num atributo de um objeto, pode escrever o seguinte: diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/commands/theme/Math.md b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/commands/theme/Math.md index 50ea4c931c579a..7fbba2beccc329 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/commands/theme/Math.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R8/commands/theme/Math.md @@ -1,6 +1,6 @@ --- id: Math_theme -title: Math +title: Funções matemáticas slug: /commands/theme/Math --- diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md index 171b5fe4c106b5..6d45ae02d16f54 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/REST/$compute.md @@ -36,7 +36,7 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev **Response**: -``` +```js { "salary": { "count": 4, @@ -54,9 +54,9 @@ Se quiser obter todos os cálculos para um atributo do tipo String, pode escreve **Response**: -``` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -70,7 +70,7 @@ Se pretender obter apenas um cálculo num atributo, pode escrever o seguinte: **Response**: -`235000` +`335000` Se pretender efetuar um cálculo num atributo de um objeto, pode escrever o seguinte: diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md index b26a54e6c1392c..fe17397fdf0290 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ Um desenvolvedor 4D pode facilmente implementar essas paletas em sua aplicação La documentación principal de [la interfaz de 4D Write Pro](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) se encuentra en el manual *Diseño 4D*. -Você encontrará abaixo a documentação de configuração do Assistente de tabelas. +You will find below: + +- the Table Wizard configuration documentation. +- the integrated A.I. documentation (*developer preview*) ## Assistente de tabelas @@ -294,4 +297,114 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### Veja também -[4D Write Pro - Table Wizard (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (vídeo tutorial)](https://www.youtube.com/watch?v=2ChlTju-mtM) + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + +#### Histórico + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-button.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-interaction.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-menu.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-resend.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/assets/en/WritePro/ai-send.png differ diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/commands/theme/Math.md b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/commands/theme/Math.md index 50ea4c931c579a..7fbba2beccc329 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/commands/theme/Math.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20-R9/commands/theme/Math.md @@ -1,6 +1,6 @@ --- id: Math_theme -title: Math +title: Funções matemáticas slug: /commands/theme/Math --- diff --git a/i18n/pt/docusaurus-plugin-content-docs/version-20/REST/$compute.md b/i18n/pt/docusaurus-plugin-content-docs/version-20/REST/$compute.md index d8a49053699667..32fd09ee6847b9 100644 --- a/i18n/pt/docusaurus-plugin-content-docs/version-20/REST/$compute.md +++ b/i18n/pt/docusaurus-plugin-content-docs/version-20/REST/$compute.md @@ -38,8 +38,7 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev `GET /rest/Employee/salary/?$compute=$all` **Resposta**: - -```` +```js { "salary": { "count": 4, @@ -51,15 +50,15 @@ Se quiser obter todos os cálculos para um atributo do tipo Número, pode escrev } ```` -Se quiser obter todos os cálculos para um atributo do tipo String, pode escrever: +If you want to get all the computations for an attribute of type String, you can write: `GET /rest/Employee/firstName/?$compute=$all` -**Resposta**: +**Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +72,7 @@ Se pretender obter apenas um cálculo num atributo, pode escrever o seguinte: **Resposta**: -`235000` +`335000` Se pretender efetuar um cálculo num atributo de um objeto, pode escrever o seguinte: diff --git a/versioned_docs/version-18/REST/$compute.md b/versioned_docs/version-18/REST/$compute.md index c993c047be70e5..21f4e18956016c 100644 --- a/versioned_docs/version-18/REST/$compute.md +++ b/versioned_docs/version-18/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,9 +57,9 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: diff --git a/versioned_docs/version-19/REST/$compute.md b/versioned_docs/version-19/REST/$compute.md index b2df9b43b5cb02..5b3aad6776f07a 100644 --- a/versioned_docs/version-19/REST/$compute.md +++ b/versioned_docs/version-19/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,9 +57,9 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: diff --git a/versioned_docs/version-20-R8/REST/$compute.md b/versioned_docs/version-20-R8/REST/$compute.md index b2df9b43b5cb02..5b3aad6776f07a 100644 --- a/versioned_docs/version-20-R8/REST/$compute.md +++ b/versioned_docs/version-20-R8/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,9 +57,9 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: diff --git a/versioned_docs/version-20-R9/REST/$compute.md b/versioned_docs/version-20-R9/REST/$compute.md index b2df9b43b5cb02..5b3aad6776f07a 100644 --- a/versioned_docs/version-20-R9/REST/$compute.md +++ b/versioned_docs/version-20-R9/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,9 +57,9 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: diff --git a/versioned_docs/version-20-R9/WritePro/writeprointerface.md b/versioned_docs/version-20-R9/WritePro/writeprointerface.md index 4895961689357d..ac5233b83b86b7 100644 --- a/versioned_docs/version-20-R9/WritePro/writeprointerface.md +++ b/versioned_docs/version-20-R9/WritePro/writeprointerface.md @@ -9,7 +9,10 @@ A 4D developer can easily implement these palettes in their application. Thus, e The main [4D Write Pro Interface documentation](https://doc.4d.com/4Dv20/4D/20/Entry-areas.300-6263967.en.html) can be found in the *4D Design Reference manual*. -You will find below the Table Wizard configuration documentation. +You will find below: + +- the Table Wizard configuration documentation, +- the integrated A.I. documentation. ## Table Wizard @@ -295,4 +298,120 @@ For every attribute used in your JSON file (header, data, carry-over, summary, a #### See also -[4D Write Pro - Table Wizard (tutorial video)](https://www.youtube.com/watch?v=2ChlTju-mtM) \ No newline at end of file +[4D Write Pro - Table Wizard (tutorial video)](https://www.youtube.com/watch?v=2ChlTju-mtM) + + +## Integrated AI + +You can use an integrated AI in the 4D Write Pro interface so that you can easily translate or enhance your documents without having to use an external AI application. + +Once you have enabled the AI feature, you can display a chat box over your 4D Write Pro document and interact with *chatGPT* to modify the text of the selection or of the document itself. + +:::note + +The 4D Write Pro interface uses OpenAI, for which you need to provide your own key (see below). + +::: + +### Limitations (Developer Preview) + +In the current implementation, the feature has the following limitations: + +- use of a predefined AI provider and necessity to pass your OpenAI key +- basic chatting features +- no image handling +- non-configurable predefined action commands +- predefined translations English/French and French/English only + + + +### Enabling the AI feature + +The AI dialog box is available by clicking on a button in the 4D Write Pro interface. This button is **hidden by default**, you need to enable it explicitely. + +To display the AI dialog box button, you need to: + +1. Get an API key from the [OpenAI website](https://openai.com/api/). +2. Execute the following 4D code: + +```4d + +WP SetAIKey ("") // + +``` + +:::note + +No checking is done on the OpenAI key validity. If it is invalid, the *chatGPT* box will stay empty. + +::: + + +The **A.I.** button is then displayed: + +![ai button](../assets/en/WritePro/ai-button.png) + +- in the 4D Write Pro Toolbar, in the **Import Export** tab, +- in the 4D Write Pro Widget, in the **Font Style** tab. + +Click on the button to display the AI dialog box. + +### AI dialog box + +The 4D Write Pro AI dialog box allows a straightforward interaction between the chat area and the 4D Write Pro document. + +#### Prompt area + +At the bottom of the window, the **prompt area** allows you to enter any question to send to the AI. + +To send your question to the AI, click on the Send button: + +![ai send](../assets/en/WritePro/ai-send.png) + + +The button icon changes when the same request is sent again: + +![ai resend](../assets/en/WritePro/ai-resend.png) + +On the left side of this area, a pop up menu provides examples of common actions that can be usually delegated to the AI. + +Selecting an action writes a corresponding question to the prompt. If necessary, you can modify the question and then to click on the Send button to actually send it: + +![ai menu](../assets/en/WritePro/ai-menu.png) + +:::note + +Default translation actions are based upon the current 4D default configuration and depend on available languages. + +::: + +#### Copy buttons + +These buttons propose basic interactions between the chat area, the underlying 4D Write Pro document, and the clipboard: + +![ai interaction](../assets/en/WritePro/ai-interaction.png) + +- **Return raw text**/**Return styled text**: Copy the latest response or the selected response from the AI to the 4D Write Pro document at the current insertion point, replacing the selected text if any. +- **Copy raw text**/**Copy styled text**: Copy the latest response or the selected response from the AI in the clipboard. + +In both cases, if the response was provided with styles, you can decide to copy the text with or without styles. + +:::note + +The chat box uses the Markdown language to format text. Basic styles such as bold, italic, underline, titles are supported. When pasting styled text from the AI in the 4D Write Pro area, you may lose some formatting information. + +::: + +#### Chat area + +The Chat area displays the whole interaction between you and the AI. You can scroll and select and part you want. + +To empty this area, you can click on the Erase button of the History area (resets the window and all interactions). + + +#### History + +The History area lists all your prompts sent to the AI. You can hide/show this area using the button on the top right corner of the Chat area. + +The Erase button allows you to reset the whole window and erase all interactions. It is equivalent to close/reopen the AI dialog box. + diff --git a/versioned_docs/version-20-R9/assets/en/WritePro/ai-button.png b/versioned_docs/version-20-R9/assets/en/WritePro/ai-button.png new file mode 100644 index 00000000000000..000d46266cdbaa Binary files /dev/null and b/versioned_docs/version-20-R9/assets/en/WritePro/ai-button.png differ diff --git a/versioned_docs/version-20-R9/assets/en/WritePro/ai-interaction.png b/versioned_docs/version-20-R9/assets/en/WritePro/ai-interaction.png new file mode 100644 index 00000000000000..ba714f027d76dd Binary files /dev/null and b/versioned_docs/version-20-R9/assets/en/WritePro/ai-interaction.png differ diff --git a/versioned_docs/version-20-R9/assets/en/WritePro/ai-menu.png b/versioned_docs/version-20-R9/assets/en/WritePro/ai-menu.png new file mode 100644 index 00000000000000..18a92f57daac20 Binary files /dev/null and b/versioned_docs/version-20-R9/assets/en/WritePro/ai-menu.png differ diff --git a/versioned_docs/version-20-R9/assets/en/WritePro/ai-resend.png b/versioned_docs/version-20-R9/assets/en/WritePro/ai-resend.png new file mode 100644 index 00000000000000..d02347a21c3b19 Binary files /dev/null and b/versioned_docs/version-20-R9/assets/en/WritePro/ai-resend.png differ diff --git a/versioned_docs/version-20-R9/assets/en/WritePro/ai-send.png b/versioned_docs/version-20-R9/assets/en/WritePro/ai-send.png new file mode 100644 index 00000000000000..e36ae899cb614a Binary files /dev/null and b/versioned_docs/version-20-R9/assets/en/WritePro/ai-send.png differ diff --git a/versioned_docs/version-20/REST/$compute.md b/versioned_docs/version-20/REST/$compute.md index b2df9b43b5cb02..5b3aad6776f07a 100644 --- a/versioned_docs/version-20/REST/$compute.md +++ b/versioned_docs/version-20/REST/$compute.md @@ -39,7 +39,7 @@ If you want to get all the computations for an attribute of type Number, you can **Response**: -```` +```js { "salary": { "count": 4, @@ -57,9 +57,9 @@ If you want to get all the computations for an attribute of type String, you can **Response**: -```` +```js { - "salary": { + "firstName": { "count": 4, "min": Anne, "max": Victor @@ -73,7 +73,7 @@ If you want to just get one calculation on an attribute, you can write the follo **Response**: -`235000` +`335000` If you want to perform a calculation on an Object attribute, you can write the following: