[PR #4] [CLOSED] Add worksheet_merge_range to merge ranges of cells #400

Closed
opened 2026-05-05 12:14:56 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jmcnamara/libxlsxwriter/pull/4
Author: @bradediger
Created: 4/2/2015
Status: Closed

Base: masterHead: merge_cells


📝 Commits (1)

  • 833f229 Add worksheet_merge_range to merge ranges of cells

📊 Changes

6 files changed (+186 additions, -0 deletions)

View changed files

📝 include/xlsxwriter/worksheet.h (+32 -0)
📝 src/worksheet.c (+98 -0)
test/functional/src/test_data08.c (+22 -0)
📝 test/functional/test_write_data.py (+3 -0)
test/functional/xlsx_files/data08.xlsx (+0 -0)
test/unit/worksheet/test_worksheet_write_merge_ranges.c (+31 -0)

📄 Description

I noticed that cell merging was missing from libxlsxwriter. I added a simple worksheet_merge_range function that doesn't support formatting or setting data but rather merges predefined cells, for example:

worksheet_write_string(worksheet, 0, 0, "Merged two rows and two columns", NULL);
worksheet_merge_range(worksheet, 0, 0, 1, 1);

It's pretty simple right now but it's working well for me. Let me know if you have any comments or suggestions.

Thanks for making libxlsxwriter available; it's been quite helpful!


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jmcnamara/libxlsxwriter/pull/4 **Author:** [@bradediger](https://github.com/bradediger) **Created:** 4/2/2015 **Status:** ❌ Closed **Base:** `master` ← **Head:** `merge_cells` --- ### 📝 Commits (1) - [`833f229`](https://github.com/jmcnamara/libxlsxwriter/commit/833f2299f5cfb4b1d311a3d0b6fa7a901ed8a9ef) Add worksheet_merge_range to merge ranges of cells ### 📊 Changes **6 files changed** (+186 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `include/xlsxwriter/worksheet.h` (+32 -0) 📝 `src/worksheet.c` (+98 -0) ➕ `test/functional/src/test_data08.c` (+22 -0) 📝 `test/functional/test_write_data.py` (+3 -0) ➕ `test/functional/xlsx_files/data08.xlsx` (+0 -0) ➕ `test/unit/worksheet/test_worksheet_write_merge_ranges.c` (+31 -0) </details> ### 📄 Description I noticed that cell merging was missing from libxlsxwriter. I added a simple `worksheet_merge_range` function that doesn't support formatting or setting data but rather merges predefined cells, for example: ``` c worksheet_write_string(worksheet, 0, 0, "Merged two rows and two columns", NULL); worksheet_merge_range(worksheet, 0, 0, 1, 1); ``` It's pretty simple right now but it's working well for me. Let me know if you have any comments or suggestions. Thanks for making libxlsxwriter available; it's been quite helpful! --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 12:14:56 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/libxlsxwriter#400
No description provided.