Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type QR ¶
type QR struct {
// contains filtered or unexported fields
}
QR represents a generated QR code.
func New ¶
func New(content string, size Size, level RecoveryLevel) (*QR, error)
New creates a new QR code with the given content, size, and recovery level.
func (*QR) ImageWithSize ¶
ImageWithSize returns the QR code as an image.Image with a custom size.
func (*QR) PNGWithSize ¶
PNGWithSize returns the QR code as PNG bytes with a custom size.
type RecoveryLevel ¶
type RecoveryLevel int
RecoveryLevel represents the error correction level for QR codes.
const ( Low RecoveryLevel = iota // 7% recovery Medium // 15% recovery High // 25% recovery Highest // 30% recovery )
Click to show internal directories.
Click to hide internal directories.