Skip to content

Document.AddPicture Imports Images Sideways #63

@LucoseGlucose

Description

@LucoseGlucose

Issue Description

Document.AddPicture Imports Images Sideways. They are not in the correct orientation even if I rotate the images themselves

Steps to Reproduce

  1. Create new go project
  2. Add godocx
  3. Create new document
  4. Add Picture and save

Expected Behavior

The picture should appear in the correct orientation

Actual Behavior

The picture appears sideways

Environment Details

  • GoDocx Library Version: v0.1.5
  • Go Version: 1.24.1
  • Operating System: Windows
  • Word Processor Used: Word
  • Word Processor Version: Version 2502 Build 16.0.18526.20168

Sample Code

doc, _ := godocx.NewDocument()
doc.AddPicture("20250325_175712.jpg", units.Inch(3), units.Inch(4))
doc.SaveTo("doc.docx")

Additional Information

doc.docx
20250325_175712.jpg

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions