The Message Log (

) form object adds a
Messages window where you can add messages to inform the user about operations that the application carries out using the built-in
message(String message) method. Enter the name of the message log object in the
Name field.
The Include standard message log toolbar check box is selected by default, which includes the toolbar in the
Messages window that you see on the COMSOL Desktop. Clear the check box to remove it. The
Show COMSOL messages check box is selected by default to include messages from the COMSOL Multiphysics software in the
Messages window. Clear the check box to only include messages from the application itself. Select the
Add timestamps to messages check box to start each message with a timestamp that provides the current date and time.
In addition, the Settings window has the following section.
The need to specify the alignment is most obvious when working in the grid mode, as it controls how the form object is aligned in its grid cell. Aligning the form object can be useful in the sketch mode too, and you can then use the alignment tools on the Arrange menu in the
Form toolbar’s
Sketch section. When running the application in any client other than the Windows client, the form objects may not be positioned exactly as seen in the form windows. This is because the form objects may have a different size in other clients, giving them a slightly different positioning. Specifying the alignment ensures that the form objects are aligned as you want them to be in all clients.
You can also specify the width and height of the Messages window. To adjust the width, enter a width (in points) in the
Width field. If you have chosen
Fill from the
Horizontal alignment list, you can instead specify a
Minimum width. Choose
Automatic to compute the minimum width automatically (typically, this means a minimum size of 0) or choose
Manual to specify a minimum width in the text field underneath. To adjust the height, enter a height (in points) in the
Height field. If you have chosen
Fill from the
Vertical alignment list, you can instead specify a
Minimum height. Choose
Automatic to compute the minimum height automatically (typically, this means a minimum size of 0) or choose
Manual to specify a minimum height in the text field underneath.
Additionally, in the sketch mode, you can specify the form object’s absolute position using the Position x and
Position y fields. In the grid mode, you can position the object in the grid and see the grid position as the
Row,
Column,
Row span, and
Column span values.
Under Cell margin (in grid mode only), you can control the margins around the form object. By default, the margins are taken from the parent form. From the
Cell margin list, choose:
From the Text color list, select a color to use for the text in the message log:
Inherit (the default; the form object then uses the setting from the Form it is located in), any of the predefined basic colors, or
Custom, which makes it possible to select a custom color from a color palette.
From the Background color list, select a color to use as the background in the message log:
Transparent (the default), any of the predefined basic colors, or
Custom, which makes it possible to select a custom color from a color palette.
The font and the font size for the text use the font settings from the Forms node by default. Select a font from the
Font list:
Default font or any of the available fonts. If needed, choose or enter a font size (in points) in the
Font size combo box. The default is to use the
Default size for the font.
You can also select the Bold check box to use a boldface font or the
Italic check box to use italics (an italic font).
Under State, you can control the initial state of the message log when users run the application. By default, the message log is visible and enabled. Clear the
Visible or
Enabled check box if you want to make the initial state so that the message log is hidden or unavailable. You can then make it visible or enable it using a method. In the Form Editor, the state of the form object is indicated by a change in its appearance. Objects that are hidden become visible when selected in the Form Editor.