extended-selectors
Syntax
[extended-selector[ ,extended-selector...]]
where extended-selector is:
[ first | last| midway ] {section-selector| blockname[inline-block-def] | overlayname}
where inline-block-def is:
[ block-params ] extended-selectorsParameters
| Places the selected sections, block, or overlay first in the containing placement directive, block, or overlay. |
| Places the selected sections, block or overlay last in the containing placement directive, block, or overlay. |
| Places the selected sections, block, or overlay so that they are no further than half the maximum size of the containing block away from either edge of the block. Note that this parameter can only be used inside a block that has a maximum size. |
| The name of the block or overlay. |
Description
Use extended-selectors to select content for inclusion in a placement directive, block, or overlay. In addition to using section selection patterns, you can also explicitly specify blocks or overlays for inclusion.
Using the first or last keyword, you can specify one pattern, block, or overlay to be placed first or last in the containing placement directive, block, or overlay. Note that:
The
firstorlastkeyword is local to the scope in which it is used—it has no effect outside that scope.If
firstis used inside a block, it has no effect on the block itself.If a
place indirective contains alastkeyword that targets a region that also is the target of otherplace indirectives, thelastkeyword will only place its content last in the placement directive in which was defined—it has no effect on the others.If you want to place something last in a region, you must define a single block that contains everything, or place everything with a single
place indirective that targets that region.
If you need more precise control of the placement order, you can instead use a block with fixed order.
Blocks can be defined separately, using the define block directive, or inline, as part of an extended-selector.
The midway parameter is primarily useful together with a static base that can have both negative and positive offsets.
Example
define block First { ro section .f* }; /* Define a block holding
any read-only section*/
matching ".f*" */
define block Table { first block First, ro section .b* };
/* Define a block where
the block First comes
before the sections
matching ".b*". */You can also define the block First inline, instead of in a separate define block directive:
define block Table { first block First { ro section .f* },
ro section .b* };See also
define block directive, define overlay directive, and place at directive.