Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Commit

Permalink
added gtk_grid_remove_row/column convenience function
Browse files Browse the repository at this point in the history
  • Loading branch information
bjarthur committed Jan 18, 2016
1 parent 81a6713 commit 9137d94
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/layout.jl
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,16 @@ if gtk_version == 3
end
end

function deleteat!(grid::GtkGrid, i::Integer, side::Symbol)
if side == :row
ccall((:gtk_grid_remove_row,libgtk), Void, (Ptr{GObject}, Cint), grid, i)
elseif side == :col
ccall((:gtk_grid_remove_column,libgtk), Void, (Ptr{GObject}, Cint), grid, i)
else
error(string("invalid GtkPositionType ",s))
end
end

function insert!(grid::GtkGrid, sibling, side::Symbol)
ccall((:gtk_grid_insert_next_to,libgtk), Void, (Ptr{GObject}, Ptr{GObject}, Cint), grid, sibling, GtkPositionType.(side))
end
Expand Down

0 comments on commit 9137d94

Please sign in to comment.