Difference between revisions of "Unit GlobalConfig"

From Ultibo.org
Jump to: navigation, search
Line 130: Line 130:
 
<pre style="border: 0; padding-bottom:0px;">function HIBYTE(W:LongInt):Byte; inline;</pre>
 
<pre style="border: 0; padding-bottom:0px;">function HIBYTE(W:LongInt):Byte; inline;</pre>
 
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Return the high byte of W</div>
 
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Return the high byte of W</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Note'''
 +
| ''None applicable''
 +
|-
 +
|}
 +
</div></div>
 +
<br />
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function LOBYTE(W:LongInt):Byte; inline;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Return the low byte of W</div>
 
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 
{| class="wikitable" style="font-size: 14px; background: white;"
 
{| class="wikitable" style="font-size: 14px; background: white;"
Line 139: Line 151:
 
</div></div>
 
</div></div>
 
<br />  
 
<br />  
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function MAKELONG(A,B:LongInt):LongInt; inline;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Make a longword value from A and B</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Note'''
 +
| ''None applicable''
 +
|-
 +
|}
 +
</div></div>
 +
<br />
 +
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function MAKEWORD(A,B:LongInt):Word; inline;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Make a word value from A and B</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Note'''
 +
| ''None applicable''
 +
|-
 +
|}
 +
</div></div>
 +
<br /> 
  
 
Return to [[Unit_Reference|Unit Reference]]
 
Return to [[Unit_Reference|Unit Reference]]

Revision as of 06:32, 21 September 2016

Return to Unit Reference


Description


The GlobalConfig unit contains variables used throughout Ultibo core to provide configuration and parameters to common modules and sub systems. Many of these variables may also be passed on the command line as environment variables to customize the behavior of Ultibo core without needing to recompile the application. This unit also includes a small number of widely used common functions.

Constants


None defined

Type definitions


None defined

Public variables


To be documented

GetLastErrorHandler:TGetLastError; - Registered handler for the global GetLastError function
SetLastErrorHandler:TSetLastError; - Registered handler for the global SetLastError function

Function declarations



Global functions

function Min(A,B:LongInt):LongInt; inline;
Description: Return the minimum value of A and B
Note None applicable


function Max(A,B:LongInt):LongInt; inline;
Description: Return the maximum value of A and B
Note None applicable


function Clamp(Value,Low,High:LongInt):LongInt;
Description: To be documented
Note None applicable


function RoundUp(Value,Multiple:LongWord):LongWord;
Description: Round Value to the next highest multiple of Multiple
Note None applicable


function RoundDown(Value,Multiple:LongWord):LongWord;
Description: Round Value to the next lowest multiple of Multiple
Note None applicable


function DivRoundClosest(Value,Divisor:LongInt):LongWord;
Description: To be documented
Note None applicable


function HIWORD(L:LongInt):Word; inline;
Description: Return the high word of L
Note None applicable


function LOWORD(L:LongInt):Word; inline;
Description: Return the low word of L
Note None applicable


function HIBYTE(W:LongInt):Byte; inline;
Description: Return the high byte of W
Note None applicable


function LOBYTE(W:LongInt):Byte; inline;
Description: Return the low byte of W
Note None applicable


function MAKELONG(A,B:LongInt):LongInt; inline;
Description: Make a longword value from A and B
Note None applicable


function MAKEWORD(A,B:LongInt):Word; inline;
Description: Make a word value from A and B
Note None applicable


Return to Unit Reference