Commit e0b8498a authored by Christophe Geuzaine's avatar Christophe Geuzaine

prepare Gmsh 4.0 :-)

parent b6d8d6a1
Pipeline #2270 passed with stage
in 70 minutes 17 seconds
......@@ -93,9 +93,9 @@ opt(WRAP_JAVA "Enable generation of Java wrappers for private API" OFF)
opt(WRAP_PYTHON "Enable generation of Python wrappers for private API" OFF)
opt(ZIPPER "Enable Zip file compression/decompression" OFF)
set(GMSH_MAJOR_VERSION 3)
set(GMSH_MAJOR_VERSION 4)
set(GMSH_MINOR_VERSION 0)
set(GMSH_PATCH_VERSION 7)
set(GMSH_PATCH_VERSION 0)
set(GMSH_EXTRA_VERSION "")
if(NOT GMSH_RELEASE)
......
......@@ -3096,10 +3096,12 @@ void status_options_cb(Fl_Widget *w, void *data)
if(opt_mesh_volumes_edges(0, GMSH_GET, 0)) menu[a + 18].set(); else menu[a + 18].clear();
if(opt_mesh_volumes_faces(0, GMSH_GET, 0)) menu[a + 19].set(); else menu[a + 19].clear();
if(PView::list.empty()){
// if there are no post-processing view, hide all entries below the mesh options...
menu[a + 23].flags = 0;
for(int i = 24; i < 42; i++) menu[a + i].hide();
}
else{
// otherwise add a divider and show the post-pro view entries
menu[a + 23].flags = FL_MENU_DIVIDER;
for(int i = 24; i < 42; i++) menu[a + i].show();
menu[a + 24].clear();
......@@ -3110,6 +3112,7 @@ void status_options_cb(Fl_Widget *w, void *data)
}
}
}
// popup the menu
static Fl_Menu_Item *picked = &menu[a + 21];
picked = (Fl_Menu_Item*)menu->popup(Fl::event_x(), Fl::event_y(), 0,
(picked && picked->visible()) ? picked :
......
......@@ -376,7 +376,7 @@ bool PView::write(const std::string &fileName, int format, bool append)
else if(ext == ".stl")
ret = _data->writeSTL(fileName);
else if(ext == ".msh")
ret = _data->writeMSH(fileName, CTX::instance()->mesh.mshFileVersion,
ret = _data->writeMSH(fileName, 2.2,
CTX::instance()->mesh.binary,
CTX::instance()->post.saveMesh, append, 0,
CTX::instance()->post.saveInterpolationMatrices,
......
......@@ -6,7 +6,7 @@
#ifndef _GMSH_H_
#define _GMSH_H_
// This file defines the Gmsh C++ API (v3.0).
// This file defines the Gmsh C++ API (v4.0).
//
// Do not edit it directly: it is automatically generated by `api/gen.py'.
//
......@@ -22,7 +22,7 @@
#include <string>
#include <utility>
#define GMSH_API_VERSION "3.0"
#define GMSH_API_VERSION "4.0"
#if defined(GMSH_DLL)
#if defined(GMSH_DLL_EXPORT)
......
......@@ -6,7 +6,7 @@
#ifndef _GMSH_H_
#define _GMSH_H_
// This file redefines the Gmsh C++ API in terms of the C API (v3.0).
// This file redefines the Gmsh C++ API in terms of the C API (v4.0).
//
// This is provided as a convenience for users of the binary Gmsh SDK whose C++
// compiler ABI is not compatible with the ABI of the C++ compiler used to create
......
......@@ -3,7 +3,7 @@
# See the LICENSE.txt file for license information. Please report all
# bugs and problems to the public mailing list <gmsh@onelab.info>.
# This file defines the Gmsh Julia API (v3.0).
# This file defines the Gmsh Julia API (v4.0).
#
# Do not edit it directly: it is automatically generated by `api/gen.py'.
#
......@@ -17,9 +17,9 @@ Top-level functions
"""
module gmsh
const GMSH_API_VERSION = "3.0"
const GMSH_API_VERSION = "4.0"
const libdir = dirname(@__FILE__)
const lib = joinpath(libdir, is_windows() ? "gmsh-3.0" : "libgmsh")
const lib = joinpath(libdir, is_windows() ? "gmsh-4.0" : "libgmsh")
"""
gmsh.initialize(argv = Vector{String}(), readConfigFiles = true)
......
......@@ -3,7 +3,7 @@
# See the LICENSE.txt file for license information. Please report all
# bugs and problems to the public mailing list <gmsh@onelab.info>.
# This file defines the Gmsh Python API (v3.0).
# This file defines the Gmsh Python API (v4.0).
#
# Do not edit it directly: it is automatically generated by `api/gen.py'.
#
......@@ -17,12 +17,12 @@ import os
import platform
from math import pi
GMSH_API_VERSION = "3.0"
GMSH_API_VERSION = "4.0"
signal.signal(signal.SIGINT, signal.SIG_DFL)
libdir = os.path.dirname(os.path.realpath(__file__))
if platform.system() == 'Windows':
lib = CDLL(os.path.join(libdir, "gmsh-3.0.dll"))
lib = CDLL(os.path.join(libdir, "gmsh-4.0.dll"))
elif platform.system() == 'Darwin':
lib = CDLL(os.path.join(libdir, "libgmsh.dylib"))
else:
......
......@@ -9,7 +9,7 @@
#define _GMSHC_H_
/*
* This file defines the Gmsh C API (v3.0).
* This file defines the Gmsh C API (v4.0).
*
* Do not edit it directly: it is automatically generated by `api/gen.py'.
*
......@@ -19,7 +19,7 @@
#include <stddef.h>
#define GMSH_API_VERSION "3.0"
#define GMSH_API_VERSION "4.0"
#if defined(GMSH_DLL)
#if defined(GMSH_DLL_EXPORT)
......
......@@ -4,10 +4,10 @@
@ftable @code
@item initialize
Initialize Gmsh. This must be called before any call to the other functions in
the API. If @code{argc} and @code{argv} are provided, they will be handled in
the same way as the command line arguments in the Gmsh app. If
@code{readConfigFiles} is set, read system Gmsh configuration files (gmshrc and
gmsh-options).
the API. If @code{argc} and @code{argv} (or just @code{argv} in Python or Julia)
are provided, they will be handled in the same way as the command line arguments
in the Gmsh app. If @code{readConfigFiles} is set, read system Gmsh
configuration files (gmshrc and gmsh-options).
@table @asis
@item Input:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment