Pasang Mara Pdf May 2026

report = generate_pasang_mara_report("Kamal Perera", "ඔබගේ මෙම කාලය ඉතා සුබදායකයි...") print(f"PDF Generated: report")

Objective: To allow users to input astrological data and automatically generate a professionally formatted, printable PDF document of the "Pasang Mara" (astrological forecast or matching report) that can be shared via WhatsApp, Email, or printed physically. pasang mara pdf


Here is a conceptual example of how this feature would be implemented using a library like fpdf (Python) or jspdf (JavaScript). Objective: To allow users to input astrological data

Python Example (using fpdf):

from fpdf import FPDF

class PasangMaraPDF(FPDF): def header(self): # Add Logo self.image('astrology_logo.png', 10, 8, 33) # Set Font (Must include Sinhala/Tamil compatible font file) self.add_font('SinhalaFont', '', 'NotoSansSinhala-Regular.ttf', uni=True) self.set_font('SinhalaFont', '', 15) self.cell(0, 10, 'පසංග මාර වාර්තාව', 0, 1, 'C') # Title in Sinhala self.ln(10) Here is a conceptual example of how this

def footer(self):
    self.set_y(-15)
    self.set_font('Arial', 'I', 8)
    self.cell(0, 10, f'Page self.page_no()', 0, 0, 'C')

def generate_pasang_mara_report(client_name, prediction_text): pdf = PasangMaraPDF() pdf.add_page()

# Client Details
pdf.set_font('Arial', 'B', 12)
pdf.cell(0, 10, f"Client: client_name", 0, 1)
# The Prediction Content
pdf.set_font('SinhalaFont', '', 12)
# Multi_cell allows for wrapping text
pdf.multi_cell(0, 10, prediction_text)
# Draw Astro Chart (Placeholder logic)
# pdf.image('generated_chart.png', x=50, y=100, w=100)
# Output
file_name = f"client_name_PasangMara_Report.pdf"
pdf.output(file_name)
return file_name