MCPcopy Index your code
hub / github.com/lxn/walk / ApplyDPI

Method ApplyDPI

tableview.go:394–414  ·  view source on GitHub ↗
(dpi int)

Source from the content-addressed store, hash-verified

392}
393
394func (tv *TableView) ApplyDPI(dpi int) {
395 tv.style.dpi = dpi
396 if tv.style.canvas != nil {
397 tv.style.canvas.dpi = dpi
398 }
399
400 tv.WidgetBase.ApplyDPI(dpi)
401
402 for _, column := range tv.columns.items {
403 column.update()
404 }
405
406 if tv.hIml != 0 {
407 tv.disposeImageListAndCaches()
408
409 if bmp, err := NewBitmapForDPI(SizeFrom96DPI(Size{16, 16}, dpi), dpi); err == nil {
410 tv.applyImageListForImage(bmp)
411 bmp.Dispose()
412 }
413 }
414}
415
416func (tv *TableView) ApplySysColors() {
417 tv.WidgetBase.ApplySysColors()

Callers

nothing calls this directly

Calls 7

NewBitmapForDPIFunction · 0.85
SizeFrom96DPIFunction · 0.85
ApplyDPIMethod · 0.65
DisposeMethod · 0.65
updateMethod · 0.45

Tested by

no test coverage detected