utils

package
v0.0.0-...-4a590b8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddImage

func AddImage(pdf *gofpdf.Fpdf, image string, x, y, w, h float64) *gofpdf.Fpdf

AddImage agrega imagen de archivo a pdf, w o h en cero autoajusta segun ratio imagen

func EncodePDF

func EncodePDF(pdf *gofpdf.Fpdf) string

EncodePDF convierte pdf a base64

func FontStyle

func FontStyle(pdf *gofpdf.Fpdf, style string, size float64, bw int, fontFamily string)

func GetFacultadDelProyectoC

func GetFacultadDelProyectoC(projectIdOikos string) (map[string]any, error)

func GetProyectoCurricular

func GetProyectoCurricular(proyectoId int) (map[string]any, error)

func Hex2RGB

func Hex2RGB(hexString string) ([3]int, error)

func Map2String

func Map2String(inMap map[string]any) (string, error)

func MapValues

func MapValues[M ~map[K]V, K comparable, V any](m M) []V

func SplitTrimSpace

func SplitTrimSpace(s, sep string) []string

SplitTrimSpace use Split function to slices s into all substrings separated by sep and use TrimSpace to remove space and return a slice of the substrings.

Types

type PageStyle

type PageStyle struct {
	ML                    float64 // margen izq
	MT                    float64 // margen sup
	MR                    float64 // margen der
	MB                    float64 // margen inf
	WW                    float64 // ancho area trabajo
	HW                    float64 // alto area trabajo
	HH                    float64 // alto header
	HB                    float64 // alto body
	HF                    float64 // alto footer
	BaseColorRGB          [3]int
	SecondaryColorRGB     [3]int
	ComplementaryColorRGB [3]int
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL