History log of /freebsd-13.1/stand/lua/drawer.lua (Results 1 – 25 of 63)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: release/12.4.0, release/13.1.0, release/12.3.0
# 0c675cb9 08-Sep-2021 Kyle Evans <[email protected]>

lualoader: allow brands to specify a shift

Some brands will want to specify a shift to make sure they're properly
centered; let it happen.

(cherry picked from commit e19d9a9b6e44e15087a140a26ab3e24

lualoader: allow brands to specify a shift

Some brands will want to specify a shift to make sure they're properly
centered; let it happen.

(cherry picked from commit e19d9a9b6e44e15087a140a26ab3e24b07f6ba56)

show more ...


# b359fcb1 08-Sep-2021 Kyle Evans <[email protected]>

lualoader: remove shadowed local from graphics:drawitem()

for loop vars are local already and distinct from this earlier
declaration; remove it.

(cherry picked from commit 763bcebe0b6d5e53e5c8940a6

lualoader: remove shadowed local from graphics:drawitem()

for loop vars are local already and distinct from this earlier
declaration; remove it.

(cherry picked from commit 763bcebe0b6d5e53e5c8940a677de662e5652b6d)

show more ...


# eabfffcb 21-Apr-2021 Toomas Soome <[email protected]>

loader: do not output empty menu title

As we output spaces around the menu title, we should also check,
if the title is actually empty string.

PR: 255299
Submitted by: Jose Luis Duran
Reported by:

loader: do not output empty menu title

As we output spaces around the menu title, we should also check,
if the title is actually empty string.

PR: 255299
Submitted by: Jose Luis Duran
Reported by: Jose Luis Duran

(cherry picked from 4ba91fa0736bb0672d475b6b56d9e7b06e78ff69)

show more ...


Revision tags: release/13.0.0
# d019c774 23-Mar-2021 Toomas Soome <[email protected]>

loader: insert spaces around menu title

Small visual nit, make menu title more clean

(cherry picked from 62ffcaab8f3ccba6053d4a5622c5ef2de9f636b5)


# b72a2e3f 08-Feb-2021 Toomas Soome <[email protected]>

loader: remove BORDER_PIXELS

BORDER_PIXELS is left over from picking up the source from illumos
port. Since FreeBSD VT does not use border in terminal size
calculation, there is no reason why should

loader: remove BORDER_PIXELS

BORDER_PIXELS is left over from picking up the source from illumos
port. Since FreeBSD VT does not use border in terminal size
calculation, there is no reason why should loader use it.

MFC after: 1 week

(cherry picke from commit 96bef2053a87c8d01ce08ea88857e4657489c8e7)

show more ...


# 994e1f40 15-Jan-2021 Kyle Evans <[email protected]>

lualoader: use floor division to get correct type

This fixes the positioning of the "Welcome to FreeBSD" heading, which was
misplaced after the recent update to Lua 5.4. The issue was previously
mas

lualoader: use floor division to get correct type

This fixes the positioning of the "Welcome to FreeBSD" heading, which was
misplaced after the recent update to Lua 5.4. The issue was previously
masked by a compatibility knob in Lua 5.3 that would cause float-tagged
numbers to render faithfully without the decimal component. Lua 5.4 dropped
that and ensures that it always prints a decimal component, even if it has
to append a ".0" to the value.

Standard division produces a "float", floor division (//) can be used to
guarantee an integer. Floating point operations have been completely ripped
out of the liblua compiled for the bootloader, so this is a nop. This is
decidedly better than trying to hack out the float tag entirely.

Reported-by: mjg, probably others
MFC-after: 3 days

show more ...


# 3630506b 21-Dec-2020 Toomas Soome <[email protected]>

loader: implement framebuffer console

Draw console on efi.
Add vbe framebuffer for BIOS loader (vbe off, vbe on, vbe list,
vbe set xxx).
autoload font (/boot/fonts) based on resolution and font size

loader: implement framebuffer console

Draw console on efi.
Add vbe framebuffer for BIOS loader (vbe off, vbe on, vbe list,
vbe set xxx).
autoload font (/boot/fonts) based on resolution and font size.
Add command loadfont (set font by file) and
variable screen.font (set font by size). Pass loaded font to kernel.

Export variables:
screen.height
screen.width
screen.depth

Add gfx primitives to draw the screen and put png image on the screen.
Rework menu draw to iterate list of consoles to enamble device specific
output.

Probably something else I forgot...

Relnotes: yes
Differential Revision: https://reviews.freebsd.org/D27420

show more ...


Revision tags: release/12.2.0
# 546f18f3 04-Oct-2020 Kyle Evans <[email protected]>

lualoader: improve the design of the brand-/logo- mechanism

In the previous world order, any brand/logo was forced to pull in the
drawer and call drawer.add{Brand,Logo} with the name their brand/log

lualoader: improve the design of the brand-/logo- mechanism

In the previous world order, any brand/logo was forced to pull in the
drawer and call drawer.add{Brand,Logo} with the name their brand/logo is
taking and a table describing it.

In the new world order, these files just need to return a table that maps
out graphics types to a table of the exact same format as what was
previously being passed back into the drawer. The appeal here is not needing
to grab a reference back to the drawer module and having a cleaner
data-driven looking format for these. The format has been renamed to 'gfx-*'
prefixes and each one can provide a logo and a brand.

drawer.addBrand/drawer.addLogo will remain in place until FreeBSD 13, as
there's no overhead to them and it's not yet worth the break in
compatibility with any pre-existing brands and logos.

Reviewed by: freqlabs
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D24966

show more ...


Revision tags: release/11.4.0
# 6697f577 01-Jun-2020 Kyle Evans <[email protected]>

lualoader: improve drawer error handling

At least one user has landed in a scenario where logo files appear to be
misnamed, and we failed to find them. Our fallback for missing logodefs is
orb/orbbw

lualoader: improve drawer error handling

At least one user has landed in a scenario where logo files appear to be
misnamed, and we failed to find them. Our fallback for missing logodefs is
orb/orbbw, based on the color status. In a scenario where we can't locate
the logos, though, this is not ideal. Add in one more layer of fallback
to properly just don't draw any logo if the fan has been jam packed with
foreign material.

PR: 246046
MFC after: 3 days

show more ...


Revision tags: release/12.1.0
# 90a25417 10-Sep-2019 Kyle Evans <[email protected]>

lualoader: Revert to ASCII menu frame for serial console

The box drawing characters we use aren't necessarily safe with a serial
console; for instance, in the report by npn@, these were causing his

lualoader: Revert to ASCII menu frame for serial console

The box drawing characters we use aren't necessarily safe with a serial
console; for instance, in the report by npn@, these were causing his xterm
to send back a sequence that lua picked up as input and halted the boot.
This is less than ideal.

Fallback to ASCII frames for console with 'comconsole' in it. This is a
partial revert r338108 by imp@ -- instead of removing the menu entirely and
disabling color/cursor sequences, just reverting the default frame to ASCII
is enough to not break in this setup.

Reported by: npn
Triaged and recommended by: tsoome

show more ...


# 56758831 05-Sep-2019 Toomas Soome <[email protected]>

loader: use teken teminal emulator for x86 and uefi

Replace mini cons25 emulator with teken, this does enable us proper console
terminal for loader and will make it possible to implement different
b

loader: use teken teminal emulator for x86 and uefi

Replace mini cons25 emulator with teken, this does enable us proper console
terminal for loader and will make it possible to implement different
back end callbacks to draw to screen.

At this time we still only "draw" in text mode.

show more ...


Revision tags: release/11.3.0, release/12.0.0
# 2c690e2a 19-Aug-2018 Kyle Evans <[email protected]>

lualoader: Add drawer-exported variables for default logodefs

Uncovered while writing the documentation from this, we previously
explicitly fell back to orb or orbbw if an invalid or incompatible lo

lualoader: Add drawer-exported variables for default logodefs

Uncovered while writing the documentation from this, we previously
explicitly fell back to orb or orbbw if an invalid or incompatible logodef
was selected -- in contrast to branddefs, which have an exported variable
that one can whip up a quick local.lua to override in a safe manner that
works regardless of whether or not loader.conf(5) successfully loads.

show more ...


# a9edc01b 19-Aug-2018 Kyle Evans <[email protected]>

lualoader: Hide the rest of the private interfaces

These are less controversial than the others, thus done in a separate
commit. These are all used internally and ways to override are provided via
s

lualoader: Hide the rest of the private interfaces

These are less controversial than the others, thus done in a separate
commit. These are all used internally and ways to override are provided via
soon-to-be-documented API or loader.conf(5) variables.

show more ...


# 12eaa305 19-Aug-2018 Kyle Evans <[email protected]>

lualoader: Hide most of the internal drawing functions

Ideally, all of the functionality to revamp the loader screen has associated
APIs that are flexible enough that third-party scripts wouldn't ne

lualoader: Hide most of the internal drawing functions

Ideally, all of the functionality to revamp the loader screen has associated
APIs that are flexible enough that third-party scripts wouldn't need to
override these.

show more ...


# 6112ee09 19-Aug-2018 Kyle Evans <[email protected]>

lualoader: Stop exporting drawer.draw

drawer.draw is the back-end for drawlogo and drawbrand and should not be
used directly.


Revision tags: release/11.2.0
# e21e1dbe 11-Jun-2018 Kyle Evans <[email protected]>

lualoader: Allow brand-*.lua for adding new brands

dteske@, I believe, had originally pointed out that lualoader failed to
allow logo-*.lua for new logos to be added. When correcting this mistake, I

lualoader: Allow brand-*.lua for adding new brands

dteske@, I believe, had originally pointed out that lualoader failed to
allow logo-*.lua for new logos to be added. When correcting this mistake, I
failed to do the same for brands.

Correct the sub-mistake: creating new brands is almost identical to creating
new logos, except one must use `drawer.addBrand` and 'graphic' is the only
valid key for a branddef at the moment.

While here, I've added `drawer.default_brand` to be set to name of brand to
be used (e.g. 'fbsd', project default).

Eventually this whole goolash will be documented.

Reported by: kmoore, iXsystems

show more ...


# bbb516ae 01-Apr-2018 Kyle Evans <[email protected]>

lualoader: Don't try to lookup a nil logo


# 1091c8fe 01-Apr-2018 Kyle Evans <[email protected]>

lualoader: Split logodefs out into logo-* files

This commit splits all of the logodefs/graphics out into their own own files
and provides a method for these files to register their logodefs with the

lualoader: Split logodefs out into logo-* files

This commit splits all of the logodefs/graphics out into their own own files
and provides a method for these files to register their logodefs with the
drawer. Graphics are now loaded on demand if they don't exist in the current
set of logodefs.

The drawer module becomes a little easier to navigate through without all of
the graphics mixed in. It's also easy to do one-off graphics like the
9.2 Die Hard tribute by dteske@ without adding even more to our memory
requirements.

show more ...


# 9895e5d4 21-Mar-2018 Kyle Evans <[email protected]>

lualoader: Use printc when we expect ANSI escape sequences


# 2ed9eb5d 04-Mar-2018 Kyle Evans <[email protected]>

lualoader: logdef -> logodef typo


# 2d36799a 03-Mar-2018 Kyle Evans <[email protected]>

lualoader: Shift menu+brand even for logo=none with customized pos


# 1495c98f 03-Mar-2018 Kyle Evans <[email protected]>

lualoader: Tweak positioning and fix an off-by-one

- All of our default positions were offset from forth
- Our menu frame size was smaller than in forth
- Logo/brand drawing had an off-by-one, drawi

lualoader: Tweak positioning and fix an off-by-one

- All of our default positions were offset from forth
- Our menu frame size was smaller than in forth
- Logo/brand drawing had an off-by-one, drawing one column lower on the
screen than they should have been.
- While here, switch a print() to printc() as it's expected that logos may
contain color and other escpae sequences that we'll need to honor.

show more ...


# b4353326 03-Mar-2018 Kyle Evans <[email protected]>

lualoader: Respect loader_menu_title_align

It may be set to "left" or "right" -- any other value will cause the title
to be centered.

I've chosen to position these things just inside the vertical b

lualoader: Respect loader_menu_title_align

It may be set to "left" or "right" -- any other value will cause the title
to be centered.

I've chosen to position these things just inside the vertical borders,
rather than overlapping the corners. This is an arbitrary choice and easily
amendable if this looks terrible.

show more ...


# 953d8937 03-Mar-2018 Kyle Evans <[email protected]>

lualoader: Respect loader_menu_title, prepare for align


# 223e9874 02-Mar-2018 Kyle Evans <[email protected]>

lualoader: Use global printc instead of loader.printc

r330282 registered loader.printc as printc, so use it instead. This makes
sense for a couple reasons, the major point being that it reads a litt

lualoader: Use global printc instead of loader.printc

r330282 registered loader.printc as printc, so use it instead. This makes
sense for a couple reasons, the major point being that it reads a little bit
easier and pairs nicely with the global 'print'.

Similar cases can not really be made for other loader.* functions as most of
them are either highly specific to our use-case or usually available in
other modules, such as `os`. printc does not have a standard implementation
in the Lua world(*), so we have a little more leeway with it, and it's kind
of a special case of the globally available 'print'.

(*) I've been in the Lua world for all of two weeks, so this could be wrong.

show more ...


123