Lazarus
Home
Help
TinyPortal
Search
Login
Register
Lazarus
»
Forum
»
Programming
»
General
»
[SOLVED] how to ranslate this macro
Free Pascal
Website
Downloads
Wiki
Documentation
Bugtracker
Mailing List
Lazarus
Website
Downloads (Laz+FPC)
Packages (OPM)
FAQ
Wiki
Documentation (RTL/FCL/LCL)
Bugtracker
CCR Bugs
GIT
Mailing List
Other languages
Foundation
Website
Useful Wiki Links
Project Roadmap
Getting the Source
Screenshots
How to use the forum
About donations (wiki)
Bookstore
Computer Math and Games in Pascal
(preview)
Lazarus Handbook
Search
Advanced search
WIKI Timeout issues
Please read here if you have trouble connecting to the wiki
Recent
Feature request/suggestio...
by
440bx
[
Today
at 08:06:51 am]
functional IF
by
munair
[
Today
at 07:37:37 am]
Data\Watch Breakpoint by ...
by
ALLIGATOR
[
Today
at 07:25:54 am]
Build failure
by
dbannon
[
Today
at 07:07:35 am]
dBGRidController and Erro...
by
essence-ciel
[
Today
at 06:31:37 am]
[AGREED] processing web f...
by
ADMGNS
[
Today
at 05:28:53 am]
What is the current versi...
by
Remy Lebeau
[
Today
at 04:18:49 am]
Silver Pascal Coder - Gre...
by
TBMan
[
Today
at 03:09:22 am]
FPReport designer, am I u...
by
dseligo
[
Today
at 01:19:22 am]
Things go bad when not us...
by
Bart
[June 15, 2025, 11:05:44 pm]
A Challenge for Lazarus G...
by
tfurnivall
[June 15, 2025, 10:48:42 pm]
X11Libre, finally and for...
by
Fred vS
[June 15, 2025, 09:44:08 pm]
FPC for high-performance ...
by
jwdietrich
[June 15, 2025, 09:18:34 pm]
PZ_Nes emulator
by
Seenkao
[June 15, 2025, 09:15:28 pm]
ZenGL +android + MacOS Co...
by
Seenkao
[June 15, 2025, 08:57:55 pm]
64 bits and PascalScript
by
maurog
[June 15, 2025, 08:27:56 pm]
gpio_set_irq_enabled_with...
by
Thaddy
[June 15, 2025, 07:35:29 pm]
InstallAware 2025 Sources...
by
d2010
[June 15, 2025, 05:39:29 pm]
SnapModbus
by
bobby100
[June 15, 2025, 05:34:54 pm]
Has anyone loaded ReactOS...
by
MarkMLl
[June 15, 2025, 05:24:35 pm]
TCustomGrid.OnPaint is us...
by
jamie
[June 15, 2025, 05:19:53 pm]
32-Bit MS-DOS Application...
by
Thaddy
[June 15, 2025, 04:57:40 pm]
Copy to and from clipboar...
by
d2010
[June 15, 2025, 11:34:52 am]
[SOLVED] TStringGrid.Visi...
by
EganSolo
[June 15, 2025, 10:30:20 am]
How to run an external pr...
by
vsajip
[June 15, 2025, 08:39:26 am]
« previous
next »
Print
Pages: [
1
]
Author
Topic: [SOLVED] how to ranslate this macro (Read 764 times)
Key-Real
Sr. Member
Posts: 389
[SOLVED] how to ranslate this macro
«
on:
June 21, 2024, 01:52:52 pm »
how to ranslate this macro in pascal?
Code: Pascal
[Select]
[+]
[-]
#define limitRange
(
x
,
l
,
h
)
(
(
x
)
=
(
(
x
)
<
(
l
)
?
(
l
)
:
(
x
)
>
(
h
)
?
(
h
)
:
(
x
)
)
)
«
Last Edit: June 21, 2024, 02:25:27 pm by Key-Real
»
Logged
Demo Scene
,
FlyTracker
,
FPC for PlayStation 1
,
my Repos
Fibonacci
Hero Member
Posts: 754
Internal Error Hunter
Re: how to ranslate this macro
«
Reply #1 on:
June 21, 2024, 02:08:23 pm »
Code: Pascal
[Select]
[+]
[-]
procedure
limitRange
(
var
x
:
integer
;
l
,
h
:
integer
)
;
inline
;
begin
if
x < l
then
x
:
=
l
else
if
x > h
then
x
:
=
h
;
end
;
Logged
Bart
Hero Member
Posts: 5573
Re: how to ranslate this macro
«
Reply #2 on:
June 21, 2024, 02:10:44 pm »
We have EnsureRange() in Math unit for that?
Bart
Logged
Print
Pages: [
1
]
« previous
next »
Lazarus
»
Forum
»
Programming
»
General
»
[SOLVED] how to ranslate this macro
TinyPortal
© 2005-2018