Saltar para o conteúdo principal
Versão: v20 R4 BETA

Entry

Verificação automática da ortografia

4D inclui funcionalidades de verificação ortográfica integrado e personalizável. Text type inputs can be checked, as well as 4D Write Pro documents.

A propriedade Auto Spellcheck ativa a verificação ortográfica para cada objeto. Quando usada, a verificação ortográfica é realizada automaticamente durante a entrada de dados. You can also execute the SPELL CHECKING 4D language command for each object to be checked.

Gramática JSON

NomeTipo de dadosValores possíveis
spellcheckbooleantrue, false

Objectos suportados

4D Write Pro area - Input


Permite ao usuário aceder a um menu de contexto padrão no objeto quando o formulário é executado.

For a picture type input, in addition to standard editing commands (Cut, Copy, Paste and Clear), the menu contains the Import... command, which can be used to import a picture stored in a file, as well as the Save as... command, which can be used to save the picture to disk. The menu can also be used to modify the display format of the picture: the Truncated non-centered, Scaled to fit and Scaled to fit centered prop. options are provided. The modification of the display format using this menu is temporary; it is not saved with the record.

For a multi-style text type input, in addition to standard editing commands, the context menu provides the following commands:

  • Fontes...: exibe a caixa de diálogo do sistema de fontes
  • Recent fonts: displays the names of recent fonts selected during the session. The list can store up to 10 fonts (beyond that, the last font used replaces the oldest). Por defeito, esta lista está vazia e a opção não é apresentada. You can manage this list using the SET RECENT FONTS and FONT LIST commands.
  • comandos para as modificações de estilo suportadas: tipo de letra, tamanho, estilo, cor e cor de fundo. When the user modifies a style attribute via this pop-up menu, 4D generates the On After Edit form event.

For a Web Area, the contents of the menu depend of the rendering engine of the platform. É possível controlar o acesso ao menu contextual por meio do comando WA SET PREFERENCE.

Gramática JSON

NomeTipo de dadosValores possíveis
contextMenustring"automatic" (utilizado se estiver em falta), "none"

Objectos suportados

Input - Web Area - 4D Write Pro areas


Enterable

The Enterable attribute indicates whether users can enter values into the object.

Os objectos são inseríveis por defeito. If you want to make a field or an object non-enterable for that form, you can disable the Enterable property for the object. Um objeto não inserível apenas exibe dados. Você controla os dados por meio de métodos que usam o nome do campo ou da variável. Pode ainda utilizar os eventos de formulário On Clicked, On Double Clicked, On Drag Over, On Drop, On Getting Focus e On Losing Focus com objetos não inseríveis. Isto facilita a gerenciamento de menus de contexto personalizados e permite-lhe conceber interfaces onde pode arrastar e largar e selecionar variáveis não introduzíveis.

When this property is disabled, any pop-up menus associated with a list box column via a list are disabled.

Gramática JSON

NomeTipo de dadosValores possíveis
enterablebooleantrue, false

Objectos suportados

4D Write Pro areas - Hierarchical List - Input - List Box Column - Progress Bar - Ruler - Stepper


Filtro de entrada

An entry filter controls exactly what the user can type during data entry. Unlike required lists for example, entry filters operate on a character-by-character basis. For example, if a part number always consists of two letters followed by three digits, you can use an entry filter to restrict the user to that pattern. Pode até controlar as letras e os números específicos.

Um filtro de entrada funciona apenas durante a introdução de dados. Não tem nenhum efeito na apresentação de dados após o usuário ter anulado a seleção do objeto. In general, you use entry filters and display formats together. The filter constrains data entry and the format ensures proper display of the value after data entry.

Durante a entrada de dados, um filtro de entrada avalia cada caractere conforme é digitado. If the user attempts to type an invalid character (a number instead of a letter, for example), 4D simply does not accept it. The null character remains unchanged until the user types a valid character.

Entry filters can also be used to display required formatting characters so that the user need not enter them. For example, an American telephone number consists of a three-digit area code, followed by a seven-digit number that is broken up into two groups of three and four digits, respectively. A display format can be used to enclose the area code in parentheses and display a dash after the third digit of the telephone number. When such a format is used, the user does not need to enter the parentheses or the dashes.

Definição de um filtro de entrada

Most of the time, you can use one of the built-in filters of 4D for what you need; however, you can also create and use custom filters:

  • pode introduzir diretamente uma cadeia de definição de filtro
  • or you can enter the name of an entry filter created in the Filters editor in the Toolbox. Os nomes dos filtros personalizados que criar começam com uma barra vertical (|).

Para obter informações sobre como criar filtros de entrada, consulte Códigos de filtro e formato.

Filtros de entrada predefinidos

Here is a table that explains each of the entry filter choices in the Entry Filter drop-down list:

Filtro de entradaDescrição
~APermite quaisquer letras, mas converte-as em maiúsculas.
&9Permitir apenas números.
&APermitir apenas letras maiúsculas.
&aPermitir apenas letras (maiúsculas e minúsculas).
&@Permitir apenas caracteres alfanuméricos. Sem caracteres especiais.
~a##Abreviatura do nome do estado (por exemplo, CA). Permite duas letras quaisquer, mas converte-as em maiúsculas.
!0&9##/##/##Formato de entrada de data standard. Apresentar zeros nos espaços de entrada. Permitir quaisquer números.
!0&9 Dia: ## Mês: ## Ano: ##Time entry format. Apresentar zeros nos espaços de entrada. Permitir quaisquer números. Limited to hours and minutes.
!0&9##:##Formato do registo de horas. Limitado a horas e minutos. Apresentar zeros nos espaços de entrada. São permitidos quatro números quaisquer, separados por dois pontos.
!0&9## Hrs ## Mins ## SecsFormato do registo de horas. Apresentar zeros nos espaços de entrada. Permitir dois números antes de cada palavra.
!0&9Hrs: ## Mins: ## Secs: ##Formato do registo de horas. Apresentar zeros nos espaços de entrada. Permitir dois números quaisquer depois de cada palavra.
!0&9##-##-##-##Formato do número de telefone local. Apresentar zeros nos espaços de entrada. Permitir qualquer número. Três entradas, hífen, quatro entradas.
!_&9(###)!0###-####Número de telefone interurbano. Mostrar sublinhados nos três primeiros espaços de entrada, zeros nos restantes.
!0&9###-###-###Número de telefone interurbano. Apresentar zeros nos espaços de entrada. Permitir qualquer número. Três entradas, hífen, três entradas, hífen, quatro entradas.
!0&9###-##-####Número de segurança social. Apresentar zeros nos espaços de entrada. Permitir quaisquer números.
~"A-Z;0-9; ;,;.;-"Letras maiúsculas e pontuação. Allow only capital letters, numbers, spaces, commas, periods, and hyphens.
&"a-z;0-9; ;,;.;-"Letras maiúsculas e minúsculas e pontuação. Permitir letras minúsculas, números, espaços, vírgulas, pontos e hífens.
&"0-9;.;-"Números. Só são permitidos números, pontos decimais e hífenes (sinal de menos).

Gramática JSON

NomeTipo de dadosValores possíveis
entryFilterstring
  • Entry filter code or
  • ou
  • Entry filter code or Entry filter name (filter names start with | )
  • Objectos suportados

    Combo Box - Hierarchical List - Input - List Box Column


    Focável

    When the Focusable property is enabled for an object, the object can have the focus (and can thus be activated by the keyboard for instance). It is outlined by a gray dotted line when it is selected — except when the Hide focus rectangle option has also been selected.

    An input object is always focusable if it has the Enterable property.


    • A caixa de verificação mostra o foco quando selecionada


    • A caixa de verificação está selecionada mas não pode mostrar o foco|

    When the Focusable property is selected for a non-enterable object, the user can select, copy or even drag-and-drop the contents of the area.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    focávelbooleantrue, false

    Objectos suportados

    4D Write Pro areas - Button - Check Box - Drop-down List - Hierarchical List - Input - List Box - Plug-in Area - Radio Button - Subform


    Layout do teclado

    This property associates a specific keyboard layout to an input object. For example, in an international application, if a form contains a field whose contents must be entered in Greek characters, you can associate the "Greek" keyboard layout with this field. This way, during data entry, the keyboard configuration is automatically changed when this field has the focus.

    Por padrão, o objeto utiliza a disposição atual do teclado.

    You can also set and get the keyboard dynamically using the OBJECT SET KEYBOARD LAYOUT and OBJECT Get keyboard layout commands.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    keyboardDialecttextCódigo da linguajem, por exemplo, "ar-ma" ou "cs". Ver RFC3066, ISO639 e ISO3166

    Objectos suportados

    4D Write Pro areas - Input


    Multilinha

    This property is available for inputs objects containing expressions of the Text type and fields of the Alpha and Text type. Pode ter três valores diferentes: Sim, Não, Automático (padrão).

    Automático

    • In single-line inputs, words located at the end of lines are truncated and there are no line returns.
    • Em entradas de várias linhas, 4D realiza retornos automáticos de linha:

    Não

    • In single-line inputs, words located at the end of lines are truncated and there are no line returns.
    • Nunca há retornos de linha: o texto é sempre exibido em uma única linha. If the Alpha or Text field or variable contains carriage returns, the text located after the first carriage return is removed as soon as the area is modified:

    Sim

    When this value is selected, the property is managed by the Wordwrap option.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    multilinhatext"yes", "no", "automatic" (padrão se não for definido)

    Objectos suportados

    Entrada


    Placeholder (valores provisórios)

    4D pode exibir texto com marcador de posição nos campos de seus formulários.

    Placeholder text appears as watermark text in a field, supplying a help tip, indication or example for the data to be entered. This text disappears as soon as the user enters a character in the area:

    O texto do marcador de posição é apresentado novamente se o conteúdo do campo for apagado.

    Pode ser apresentado um marcador de posição para os seguintes tipos de dados:

    • string (text ou alpha)
    • date and time when the Blank if null property is enabled.

    You can use an XLIFF reference in the ":xliff:resname" form as a placeholder, for example:

    :xliff:PH_Lastname

    You only pass the reference in the "Placeholder" field; it is not possible to combine a reference with static text.

    You can also set and get the placeholder text by programming using the OBJECT SET PLACEHOLDER and OBJECT Get placeholder commands.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    placeholderstringText to be displayed (grayed out) when the object does not contain any value

    Objectos suportados

    Combo Box - Input

    Veja também

    Dica de ajuda


    Selecção sempre visível

    This property keeps the selection visible within the object after it has lost the focus. This makes it easier to implement interfaces that allow the text style to be modified (see Multi-style).

    Gramática JSON

    NomeTipo de dadosValores possíveis
    showSelectionbooleantrue, false

    Objectos suportados

    4D Write Pro areas - Input


    Atalho

    This property allows setting special meaning keys (keyboard shortcuts) for buttons, radio buttons, and checkboxes. They allow the user to use the control using the keyboard instead of having to use the mouse.

    You can configure this option by clicking the [...] button in the Shortcuts property in the Property List.

    Também é possível atribuir um atalho a um comando de menu personalizado. Se houver um conflito entre dois atalhos, o objeto ativo terá prioridade. Para obter mais informações sobre como associar atalhos a menus, consulte Definição das propriedades dos menus.

    To view a list of all the shortcuts used in the 4D Design environment, see the Shortcuts Page in the Preferences dialog box.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    shortcutAccelbooleantrue, false (Windows: Ctrl/macOS: Command)
    shortcutAltbooleantrue, false
    shortcutCommandbooleantrue, false
    shortcutControlbooleantrue, false (macOS: Control)
    shortcutShiftbooleantrue, false
    shortcutKeystring
  • qualquer tecla de carácter: "a", "b"...
  • [F1]" -> "[F15]", "[Return]", "[Enter]", "[Backspace]", "[Tab]", "[Esc]", "[Del]", "[Home]", "[End]", "[Help]", "[Page up]", "[Page down]", "[left arrow]", "[right arrow]", "[up arrow]", "[down arrow]"
  • Objectos suportados

    Button - Check Box - Picture Button - Radio Button


    Editar com um clique

    Permite a passagem direta para o modo de edição em list boxes.

    When this option is enabled, list box cells switch to edit mode after a single user click, regardless of whether or not this area of the list box was selected beforehand. Note that this option allows cells to be edited even when the list box selection mode is set to "None".

    When this option is not enabled, users must first select the cell row and then click on a cell in order to edit its contents.

    Gramática JSON

    NomeTipo de dadosValores possíveis
    singleClickEditbooleantrue, false

    Objectos suportados

    List Box