Skip to content

Instantly share code, notes, and snippets.

@luce80
luce80 / mold-red.red
Last active Jul 11, 2020
Mold the System object
View mold-red.red
Red [
title: "Mold the System object"
author: "Marco Antoniazzi"
History: [
0.1.0 [18-08-2013 "Done"]
0.2.0 [16-04-2016 "Fixed unset values"]
0.3.0 [23-08-2018 "Added 3 dots ..."]
0.4.0 [26-08-2018 "Added checks actions"]
0.5.0 [16-05-2020 "Fixed throw(s) by adding <none>. Added undirize. Added history."]
0.6.0 [19-05-2020 "Red version"]
@luce80
luce80 / color-slider.red
Last active May 17, 2019
Red VID reactive script in 3 versions
View color-slider.red
Red [
Title: "Red VID reactive script in 3 versions"
Author: "luce80 derived from Nenad Rakocevic"
File: %color-slider.red
Needs: 'View
License: "MIT"
Notes: {
Demo of chained reactive programming, moving the sliders changes text, field, progress and the box's color
which in turn, changes the bottom text font color. Also changing field changes slider that changes all
the rest ;) .
@luce80
luce80 / add-script.red
Created Jul 1, 2018
Help update red scripts collection list
View add-script.red
Red [
title: "Update red scripts collection list"
file: %add-script.red
author: "Marco Antoniazzi"
license: "Do with this code whatever you want, giving credit to me is NOT required"
email: [luce80 AT alice DOT it]
date: 01-07-2018
version: 1.0.1
Purpose: "Help update red scripts collection list"
Needs: 'View
@luce80
luce80 / iterated-faces.red
Last active Jan 25, 2018
Create iterated faces in Red as those found in Rebol View
View iterated-faces.red
Red [
title: "Iterated faces in Red"
file: %iterated-faces.red
author: "Marco Antoniazzi"
license: "Do with this code whatever you want, giving credit to me is NOT required"
email: [luce80 AT alice DOT it]
date: 13-01-2018
version: 0.0.6
Purpose: "Create iterated faces as those found in Rebol View"
Needs: View
@luce80
luce80 / resize-image.red
Last active Dec 8, 2017
Draw Image Resizing Test with reaction
View resize-image.red
Red [
Title: "Draw Image Resizing Test"
Author: [REBOL version "Carl Sassenrath" Red port "Gregg Irwin" Reacting version "Marco Antoniazzi"]
Version: 0.0.2
File: %resize-image.red
Needs: View
]
img: load/as any [
attempt [read/binary img-url: https://pbs.twimg.com/profile_images/501701094032941056/R-a4YJ5K.png]
@luce80
luce80 / dates-calcs.red
Last active Nov 26, 2017
Some useful functions for calculations of dates
View dates-calcs.red
Red [
Author: "luce80"
Licence: 'PD
]
; from https://en.wikipedia.org/wiki/Julian_day
julian-day-number: func [day month year /local a y m] [ ; in Red 0.6.2, integer calcs give integer result so we could remove to-integer(s)
; TBD check params
a: to-integer 14 - month / 12
y: year + 4800 - a