Start completely off one side, scroll all the way across and completely off. The following pseudo-code defines the behavior when the marquee direction is to the left (see ‘marquee-direction‘). The other directions are analogous.
Set the element to clip the overflow to the left and to the right
Create an anonymous box B around the content; set its ‘width‘ so as to include all content and all overflow exactly; set its ‘margin-right‘ to ‘auto‘
Set ‘margin-left‘ of B to 100% (i.e., all contents is off to the right and thus invisible)
Decrease ‘margin-left‘ at constant speed (see ‘marquee-speed‘) until ‘margin-right‘ is 100% (i.e., all content is off to the left and thus invisible)
Decrease n by one
slide
Start completely off one side, scroll in, and stop as soon as no more content is off that side. The following pseudo-code defines the behavior when the marquee direction is to the left (see ‘marquee-direction‘). The other directions are analogous.
Set the element to clip the overflow to the left and to the right
Create an anonymous box B around the content; set its ‘width‘ so as to include all content and all overflow exactly; set its ‘margin-right‘ to ‘auto‘
Bounce back and forth. The following pseudo-code defines the behavior when the initial marquee direction is to the left (see ‘marquee-direction‘). The other directions are analogous.
Set the element to clip the overflow to the left and to the right
Create an anonymous box B around the content; set its ‘width‘ so as to include all content and all overflow exactly