├── data ├── grad.dat ├── icon.png ├── tr │ ├── en.mtr │ ├── ja.mtr │ ├── ru.mtr │ ├── uk.mtr │ ├── pt_BR.mtr │ └── zh_CN.mtr ├── brush-2.dat ├── palette-2.dat ├── 13x13 │ └── layer.png ├── 16x16 │ ├── layer.png │ ├── tool.png │ ├── toolbar.png │ ├── toolsub.png │ ├── brushedit.png │ ├── canvasview.png │ └── imgviewer.png ├── 20x20 │ ├── tool.png │ ├── toolbar.png │ ├── toolsub.png │ ├── brushedit.png │ ├── canvasview.png │ └── imgviewer.png ├── 24x24 │ ├── tool.png │ ├── toolbar.png │ ├── toolsub.png │ ├── brushedit.png │ ├── canvasview.png │ └── imgviewer.png ├── brush │ ├── circle1.png │ └── ellipse.png ├── texture │ ├── tone300 │ │ ├── 05L01.png │ │ ├── 05L02.png │ │ ├── 05L05.png │ │ ├── 05L10.png │ │ ├── 05L20.png │ │ ├── 08L01.png │ │ ├── 08L02.png │ │ ├── 08L05.png │ │ ├── 10L02.png │ │ ├── 10L05.png │ │ ├── 10L10.png │ │ ├── 10L20.png │ │ ├── 10L30.png │ │ ├── 15L02.png │ │ ├── 15L05.png │ │ ├── 15L10.png │ │ ├── 15L20.png │ │ ├── 20L02.png │ │ ├── 20L05.png │ │ ├── 20L10.png │ │ ├── 20L20.png │ │ ├── 20L30.png │ │ ├── 20L40.png │ │ ├── 30L10.png │ │ ├── 30L20.png │ │ ├── 30L30.png │ │ ├── 30L40.png │ │ ├── 40L10.png │ │ ├── 40L20.png │ │ ├── 40L30.png │ │ ├── 50L10.png │ │ ├── 50L20.png │ │ └── 60L10.png │ ├── tone600 │ │ ├── 30L05.png │ │ ├── 30L10.png │ │ ├── 30L20.png │ │ ├── 30L30.png │ │ ├── 50L05.png │ │ ├── 50L10.png │ │ ├── 50L20.png │ │ ├── 50L30.png │ │ ├── 55L05.png │ │ ├── 55L10.png │ │ ├── 55L20.png │ │ ├── 55L30.png │ │ ├── 60L05.png │ │ ├── 60L10.png │ │ ├── 60L30.png │ │ ├── 65L05.png │ │ ├── 65L10.png │ │ ├── 85L05.png │ │ ├── 27.5L05.png │ │ ├── 27.5L10.png │ │ ├── 27.5L20.png │ │ ├── 27.5L30.png │ │ ├── 27.5L40.png │ │ ├── 32.5L05.png │ │ ├── 32.5L10.png │ │ ├── 32.5L20.png │ │ ├── 32.5L30.png │ │ ├── 42.5L05.png │ │ ├── 42.5L10.png │ │ ├── 42.5L20.png │ │ └── 42.5L30.png │ └── various │ │ ├── brick.png │ │ ├── cross.png │ │ ├── dot01.png │ │ ├── dot02.png │ │ ├── dot03.png │ │ ├── dot04.png │ │ ├── dot05.png │ │ ├── dot06.png │ │ ├── dot07.png │ │ ├── dot08.png │ │ ├── dot09.png │ │ ├── dot10.png │ │ ├── heart.png │ │ ├── horz1.png │ │ ├── horz2.png │ │ ├── horz3.png │ │ ├── horz4.png │ │ ├── horz5.png │ │ ├── horz6.png │ │ ├── horz7.png │ │ ├── jag1.png │ │ ├── jag2.png │ │ ├── star.png │ │ ├── vert1.png │ │ ├── vert2.png │ │ ├── vert3.png │ │ ├── vert4.png │ │ ├── vert5.png │ │ ├── vert6.png │ │ ├── vert7.png │ │ ├── wall.png │ │ ├── check1.png │ │ ├── check2.png │ │ ├── check3.png │ │ ├── check4.png │ │ ├── check5.png │ │ ├── check6.png │ │ ├── flower.png │ │ ├── grid01.png │ │ ├── grid02.png │ │ ├── grid03.png │ │ ├── grid04.png │ │ ├── grid05.png │ │ ├── grid06.png │ │ ├── grid07.png │ │ ├── grid08.png │ │ ├── gridsl1.png │ │ ├── gridsl2.png │ │ ├── slant1.png │ │ ├── slant2.png │ │ ├── slant3.png │ │ ├── slant4.png │ │ ├── slant5.png │ │ ├── slant6.png │ │ ├── slant7.png │ │ ├── slant8.png │ │ ├── tone00.png │ │ ├── tone01.png │ │ ├── tone02.png │ │ ├── tone03.png │ │ ├── tone04.png │ │ ├── tone05.png │ │ ├── tone06.png │ │ ├── tone07.png │ │ ├── tone08.png │ │ ├── tone09.png │ │ ├── tone10.png │ │ ├── x-mark.png │ │ ├── gradient1.png │ │ ├── gradient2.png │ │ ├── speed_horz.png │ │ ├── speed_vert.png │ │ ├── square_dot.png │ │ ├── triangle1.png │ │ ├── triangle2.png │ │ └── white_circle.png ├── sckey-2.conf ├── theme │ └── black.theme └── Makefile.am ├── desktop ├── azpainter.png ├── application-x-azpainter-apd.png ├── azpainter.desktop ├── azpainter.xml └── Makefile.am ├── COPYING ├── translation ├── Makefile └── HOWTO_ja ├── Makefile.am ├── AUTHORS ├── NEWS ├── src ├── include │ ├── defDrawGlobal.h │ ├── AppResource.h │ ├── PopupThread.h │ ├── SinTable.h │ ├── PrevCursor.h │ ├── EnvOptDlg.h │ ├── FileDialog.h │ ├── draw_text.h │ ├── StatusBar.h │ ├── draw_boxedit.h │ ├── defScalingType.h │ ├── trid_word.h │ ├── trid_message.h │ ├── PrevImage8.h │ ├── ConfigData.h │ ├── PrevTileImage.h │ ├── draw_op_main.h │ ├── ColorWheel.h │ ├── FilterPrev.h │ ├── CanvasDialogs.h │ ├── BrushSizeList.h │ ├── FilterSaveData.h │ ├── SelMaterial.h │ ├── FilterBar.h │ ├── AppErr.h │ ├── SplineBuf.h │ ├── ValueBar.h │ ├── defBlendMode.h │ ├── draw_select.h │ ├── MaterialImgList.h │ ├── DrawFill.h │ ├── FilterDefWidget.h │ ├── draw_rule.h │ ├── defTileImage.h │ ├── DrawFont.h │ ├── defLoadErr.h │ ├── PixbufDraw.h │ ├── defMacros.h │ ├── defMainWinCanvas.h │ ├── defPixelMode.h │ ├── DrawPointBuf.h │ ├── ColorValue.h │ ├── dataImagePattern.h │ ├── LayerDialogs.h │ ├── defMainWindow.h │ ├── FillPolygon.h │ ├── defFileFormat.h │ ├── trid_layer_dialogs.h │ ├── defCanvasKeyID.h │ ├── ImageBuf8.h │ ├── draw_file.h │ ├── ImageBuf24.h │ ├── AppCursor.h │ ├── defCanvasInfo.h │ ├── defTool.h │ ├── FilterDrawInfo.h │ ├── TileImageDrawInfo.h │ ├── defWidgets.h │ ├── BrushDrawParam.h │ ├── DockObject.h │ ├── blendcol.h │ ├── MainWindow_pv.h │ ├── MainWinCanvas.h │ └── MainWindow.h ├── widget │ ├── PopupSliderZoom.h │ ├── PressureWidget.h │ ├── DockCanvasView.h │ ├── CanvasCtrlBar.h │ ├── DockImageViewer.h │ └── DockOption_sub.h ├── other │ ├── SinTable.c │ ├── ColorValue.c │ └── UndoMaster.h ├── filter │ └── PerlinNoise.h └── AppResource.c ├── mlib ├── src │ ├── x11 │ │ ├── x11_img_cursor.h │ │ ├── x11_dnd.h │ │ ├── x11_im.h │ │ ├── x11_window.h │ │ └── x11_xinput2.h │ └── private │ │ ├── mListViewPopup.h │ │ ├── mAppPrivate.h │ │ └── mEventList.h └── include │ ├── mConfig.h │ ├── mStrDef.h │ ├── mUtilSys.h │ ├── mEnumFont.h │ ├── mWidgetBuilder.h │ ├── mFTGSUB.h │ ├── mToolTip.h │ ├── mClipboard.h │ ├── mRandXorShift.h │ ├── mFileStat.h │ ├── mCursor.h │ ├── mListDef.h │ ├── mTextRead.h │ ├── mTreeDef.h │ ├── mContainerDef.h │ └── mNanoTime.h ├── BSD └── configure.ac /data/grad.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/grad.dat -------------------------------------------------------------------------------- /data/icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/icon.png -------------------------------------------------------------------------------- /data/tr/en.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/en.mtr -------------------------------------------------------------------------------- /data/tr/ja.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/ja.mtr -------------------------------------------------------------------------------- /data/tr/ru.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/ru.mtr -------------------------------------------------------------------------------- /data/tr/uk.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/uk.mtr -------------------------------------------------------------------------------- /data/brush-2.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/brush-2.dat -------------------------------------------------------------------------------- /data/palette-2.dat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/palette-2.dat -------------------------------------------------------------------------------- /data/tr/pt_BR.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/pt_BR.mtr -------------------------------------------------------------------------------- /data/tr/zh_CN.mtr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/tr/zh_CN.mtr -------------------------------------------------------------------------------- /data/13x13/layer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/13x13/layer.png -------------------------------------------------------------------------------- /data/16x16/layer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/layer.png -------------------------------------------------------------------------------- /data/16x16/tool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/tool.png -------------------------------------------------------------------------------- /data/20x20/tool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/tool.png -------------------------------------------------------------------------------- /data/24x24/tool.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/tool.png -------------------------------------------------------------------------------- /data/16x16/toolbar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/toolbar.png -------------------------------------------------------------------------------- /data/16x16/toolsub.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/toolsub.png -------------------------------------------------------------------------------- /data/20x20/toolbar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/toolbar.png -------------------------------------------------------------------------------- /data/20x20/toolsub.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/toolsub.png -------------------------------------------------------------------------------- /data/24x24/toolbar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/toolbar.png -------------------------------------------------------------------------------- /data/24x24/toolsub.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/toolsub.png -------------------------------------------------------------------------------- /data/brush/circle1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/brush/circle1.png -------------------------------------------------------------------------------- /data/brush/ellipse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/brush/ellipse.png -------------------------------------------------------------------------------- /desktop/azpainter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/desktop/azpainter.png -------------------------------------------------------------------------------- /data/16x16/brushedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/brushedit.png -------------------------------------------------------------------------------- /data/16x16/canvasview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/canvasview.png -------------------------------------------------------------------------------- /data/16x16/imgviewer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/16x16/imgviewer.png -------------------------------------------------------------------------------- /data/20x20/brushedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/brushedit.png -------------------------------------------------------------------------------- /data/20x20/canvasview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/canvasview.png -------------------------------------------------------------------------------- /data/20x20/imgviewer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/20x20/imgviewer.png -------------------------------------------------------------------------------- /data/24x24/brushedit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/brushedit.png -------------------------------------------------------------------------------- /data/24x24/canvasview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/canvasview.png -------------------------------------------------------------------------------- /data/24x24/imgviewer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/24x24/imgviewer.png -------------------------------------------------------------------------------- /COPYING: -------------------------------------------------------------------------------- 1 | This software is under the GPL3 License, see GPL3. 2 | 3 | mlib is under the BSD License, see BSD. 4 | -------------------------------------------------------------------------------- /translation/Makefile: -------------------------------------------------------------------------------- 1 | all: mtrconv 2 | 3 | mtrconv: mtrconv.c 4 | $(CC) -Wall -O2 -s -o mtrconv mtrconv.c 5 | -------------------------------------------------------------------------------- /data/texture/tone300/05L01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/05L01.png -------------------------------------------------------------------------------- /data/texture/tone300/05L02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/05L02.png -------------------------------------------------------------------------------- /data/texture/tone300/05L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/05L05.png -------------------------------------------------------------------------------- /data/texture/tone300/05L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/05L10.png -------------------------------------------------------------------------------- /data/texture/tone300/05L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/05L20.png -------------------------------------------------------------------------------- /data/texture/tone300/08L01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/08L01.png -------------------------------------------------------------------------------- /data/texture/tone300/08L02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/08L02.png -------------------------------------------------------------------------------- /data/texture/tone300/08L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/08L05.png -------------------------------------------------------------------------------- /data/texture/tone300/10L02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/10L02.png -------------------------------------------------------------------------------- /data/texture/tone300/10L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/10L05.png -------------------------------------------------------------------------------- /data/texture/tone300/10L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/10L10.png -------------------------------------------------------------------------------- /data/texture/tone300/10L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/10L20.png -------------------------------------------------------------------------------- /data/texture/tone300/10L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/10L30.png -------------------------------------------------------------------------------- /data/texture/tone300/15L02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/15L02.png -------------------------------------------------------------------------------- /data/texture/tone300/15L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/15L05.png -------------------------------------------------------------------------------- /data/texture/tone300/15L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/15L10.png -------------------------------------------------------------------------------- /data/texture/tone300/15L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/15L20.png -------------------------------------------------------------------------------- /data/texture/tone300/20L02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L02.png -------------------------------------------------------------------------------- /data/texture/tone300/20L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L05.png -------------------------------------------------------------------------------- /data/texture/tone300/20L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L10.png -------------------------------------------------------------------------------- /data/texture/tone300/20L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L20.png -------------------------------------------------------------------------------- /data/texture/tone300/20L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L30.png -------------------------------------------------------------------------------- /data/texture/tone300/20L40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/20L40.png -------------------------------------------------------------------------------- /data/texture/tone300/30L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/30L10.png -------------------------------------------------------------------------------- /data/texture/tone300/30L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/30L20.png -------------------------------------------------------------------------------- /data/texture/tone300/30L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/30L30.png -------------------------------------------------------------------------------- /data/texture/tone300/30L40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/30L40.png -------------------------------------------------------------------------------- /data/texture/tone300/40L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/40L10.png -------------------------------------------------------------------------------- /data/texture/tone300/40L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/40L20.png -------------------------------------------------------------------------------- /data/texture/tone300/40L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/40L30.png -------------------------------------------------------------------------------- /data/texture/tone300/50L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/50L10.png -------------------------------------------------------------------------------- /data/texture/tone300/50L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/50L20.png -------------------------------------------------------------------------------- /data/texture/tone300/60L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone300/60L10.png -------------------------------------------------------------------------------- /data/texture/tone600/30L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/30L05.png -------------------------------------------------------------------------------- /data/texture/tone600/30L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/30L10.png -------------------------------------------------------------------------------- /data/texture/tone600/30L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/30L20.png -------------------------------------------------------------------------------- /data/texture/tone600/30L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/30L30.png -------------------------------------------------------------------------------- /data/texture/tone600/50L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/50L05.png -------------------------------------------------------------------------------- /data/texture/tone600/50L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/50L10.png -------------------------------------------------------------------------------- /data/texture/tone600/50L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/50L20.png -------------------------------------------------------------------------------- /data/texture/tone600/50L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/50L30.png -------------------------------------------------------------------------------- /data/texture/tone600/55L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/55L05.png -------------------------------------------------------------------------------- /data/texture/tone600/55L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/55L10.png -------------------------------------------------------------------------------- /data/texture/tone600/55L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/55L20.png -------------------------------------------------------------------------------- /data/texture/tone600/55L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/55L30.png -------------------------------------------------------------------------------- /data/texture/tone600/60L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/60L05.png -------------------------------------------------------------------------------- /data/texture/tone600/60L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/60L10.png -------------------------------------------------------------------------------- /data/texture/tone600/60L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/60L30.png -------------------------------------------------------------------------------- /data/texture/tone600/65L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/65L05.png -------------------------------------------------------------------------------- /data/texture/tone600/65L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/65L10.png -------------------------------------------------------------------------------- /data/texture/tone600/85L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/85L05.png -------------------------------------------------------------------------------- /data/texture/various/brick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/brick.png -------------------------------------------------------------------------------- /data/texture/various/cross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/cross.png -------------------------------------------------------------------------------- /data/texture/various/dot01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot01.png -------------------------------------------------------------------------------- /data/texture/various/dot02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot02.png -------------------------------------------------------------------------------- /data/texture/various/dot03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot03.png -------------------------------------------------------------------------------- /data/texture/various/dot04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot04.png -------------------------------------------------------------------------------- /data/texture/various/dot05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot05.png -------------------------------------------------------------------------------- /data/texture/various/dot06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot06.png -------------------------------------------------------------------------------- /data/texture/various/dot07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot07.png -------------------------------------------------------------------------------- /data/texture/various/dot08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot08.png -------------------------------------------------------------------------------- /data/texture/various/dot09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot09.png -------------------------------------------------------------------------------- /data/texture/various/dot10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/dot10.png -------------------------------------------------------------------------------- /data/texture/various/heart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/heart.png -------------------------------------------------------------------------------- /data/texture/various/horz1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz1.png -------------------------------------------------------------------------------- /data/texture/various/horz2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz2.png -------------------------------------------------------------------------------- /data/texture/various/horz3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz3.png -------------------------------------------------------------------------------- /data/texture/various/horz4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz4.png -------------------------------------------------------------------------------- /data/texture/various/horz5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz5.png -------------------------------------------------------------------------------- /data/texture/various/horz6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz6.png -------------------------------------------------------------------------------- /data/texture/various/horz7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/horz7.png -------------------------------------------------------------------------------- /data/texture/various/jag1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/jag1.png -------------------------------------------------------------------------------- /data/texture/various/jag2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/jag2.png -------------------------------------------------------------------------------- /data/texture/various/star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/star.png -------------------------------------------------------------------------------- /data/texture/various/vert1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert1.png -------------------------------------------------------------------------------- /data/texture/various/vert2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert2.png -------------------------------------------------------------------------------- /data/texture/various/vert3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert3.png -------------------------------------------------------------------------------- /data/texture/various/vert4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert4.png -------------------------------------------------------------------------------- /data/texture/various/vert5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert5.png -------------------------------------------------------------------------------- /data/texture/various/vert6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert6.png -------------------------------------------------------------------------------- /data/texture/various/vert7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/vert7.png -------------------------------------------------------------------------------- /data/texture/various/wall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/wall.png -------------------------------------------------------------------------------- /data/texture/tone600/27.5L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/27.5L05.png -------------------------------------------------------------------------------- /data/texture/tone600/27.5L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/27.5L10.png -------------------------------------------------------------------------------- /data/texture/tone600/27.5L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/27.5L20.png -------------------------------------------------------------------------------- /data/texture/tone600/27.5L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/27.5L30.png -------------------------------------------------------------------------------- /data/texture/tone600/27.5L40.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/27.5L40.png -------------------------------------------------------------------------------- /data/texture/tone600/32.5L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/32.5L05.png -------------------------------------------------------------------------------- /data/texture/tone600/32.5L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/32.5L10.png -------------------------------------------------------------------------------- /data/texture/tone600/32.5L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/32.5L20.png -------------------------------------------------------------------------------- /data/texture/tone600/32.5L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/32.5L30.png -------------------------------------------------------------------------------- /data/texture/tone600/42.5L05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/42.5L05.png -------------------------------------------------------------------------------- /data/texture/tone600/42.5L10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/42.5L10.png -------------------------------------------------------------------------------- /data/texture/tone600/42.5L20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/42.5L20.png -------------------------------------------------------------------------------- /data/texture/tone600/42.5L30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/tone600/42.5L30.png -------------------------------------------------------------------------------- /data/texture/various/check1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check1.png -------------------------------------------------------------------------------- /data/texture/various/check2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check2.png -------------------------------------------------------------------------------- /data/texture/various/check3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check3.png -------------------------------------------------------------------------------- /data/texture/various/check4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check4.png -------------------------------------------------------------------------------- /data/texture/various/check5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check5.png -------------------------------------------------------------------------------- /data/texture/various/check6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/check6.png -------------------------------------------------------------------------------- /data/texture/various/flower.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/flower.png -------------------------------------------------------------------------------- /data/texture/various/grid01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid01.png -------------------------------------------------------------------------------- /data/texture/various/grid02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid02.png -------------------------------------------------------------------------------- /data/texture/various/grid03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid03.png -------------------------------------------------------------------------------- /data/texture/various/grid04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid04.png -------------------------------------------------------------------------------- /data/texture/various/grid05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid05.png -------------------------------------------------------------------------------- /data/texture/various/grid06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid06.png -------------------------------------------------------------------------------- /data/texture/various/grid07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid07.png -------------------------------------------------------------------------------- /data/texture/various/grid08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/grid08.png -------------------------------------------------------------------------------- /data/texture/various/gridsl1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/gridsl1.png -------------------------------------------------------------------------------- /data/texture/various/gridsl2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/gridsl2.png -------------------------------------------------------------------------------- /data/texture/various/slant1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant1.png -------------------------------------------------------------------------------- /data/texture/various/slant2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant2.png -------------------------------------------------------------------------------- /data/texture/various/slant3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant3.png -------------------------------------------------------------------------------- /data/texture/various/slant4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant4.png -------------------------------------------------------------------------------- /data/texture/various/slant5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant5.png -------------------------------------------------------------------------------- /data/texture/various/slant6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant6.png -------------------------------------------------------------------------------- /data/texture/various/slant7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant7.png -------------------------------------------------------------------------------- /data/texture/various/slant8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/slant8.png -------------------------------------------------------------------------------- /data/texture/various/tone00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone00.png -------------------------------------------------------------------------------- /data/texture/various/tone01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone01.png -------------------------------------------------------------------------------- /data/texture/various/tone02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone02.png -------------------------------------------------------------------------------- /data/texture/various/tone03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone03.png -------------------------------------------------------------------------------- /data/texture/various/tone04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone04.png -------------------------------------------------------------------------------- /data/texture/various/tone05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone05.png -------------------------------------------------------------------------------- /data/texture/various/tone06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone06.png -------------------------------------------------------------------------------- /data/texture/various/tone07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone07.png -------------------------------------------------------------------------------- /data/texture/various/tone08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone08.png -------------------------------------------------------------------------------- /data/texture/various/tone09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone09.png -------------------------------------------------------------------------------- /data/texture/various/tone10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/tone10.png -------------------------------------------------------------------------------- /data/texture/various/x-mark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/x-mark.png -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = mlib src data desktop 2 | EXTRA_DIST = translation README_ja BSD GPL3 \ 3 | manual/manual_ja.html 4 | -------------------------------------------------------------------------------- /data/texture/various/gradient1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/gradient1.png -------------------------------------------------------------------------------- /data/texture/various/gradient2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/gradient2.png -------------------------------------------------------------------------------- /data/texture/various/speed_horz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/speed_horz.png -------------------------------------------------------------------------------- /data/texture/various/speed_vert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/speed_vert.png -------------------------------------------------------------------------------- /data/texture/various/square_dot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/square_dot.png -------------------------------------------------------------------------------- /data/texture/various/triangle1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/triangle1.png -------------------------------------------------------------------------------- /data/texture/various/triangle2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/triangle2.png -------------------------------------------------------------------------------- /data/texture/various/white_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/data/texture/various/white_circle.png -------------------------------------------------------------------------------- /desktop/application-x-azpainter-apd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/probonopd/azpainter/master/desktop/application-x-azpainter-apd.png -------------------------------------------------------------------------------- /desktop/azpainter.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Name=AzPainter 4 | Exec=azpainter %f 5 | Icon=azpainter 6 | Terminal=false 7 | Categories=Graphics; 8 | MimeType=application/x-azpainter-apd; 9 | StartupNotify=true 10 | -------------------------------------------------------------------------------- /data/sckey-2.conf: -------------------------------------------------------------------------------- 1 | [sckey] 2 | 1000=404e 3 | 1001=404f 4 | 1002=4053 5 | 1003=4057 6 | 2000=405a 7 | 2001=4059 8 | 2003=d 9 | 2004=c 10 | 3000=4044 11 | 3001=4049 12 | 3002=4041 13 | 3003=4043 14 | 3004=4058 15 | 3005=4056 16 | 3006=4045 17 | 6001=4051 18 | 6003=4047 19 | 6004=404d 20 | -------------------------------------------------------------------------------- /AUTHORS: -------------------------------------------------------------------------------- 1 | # translation 2 | ------------------- 3 | 4 | pt_BR 5 | Adriano Duarte 6 | 7 | ru 8 | Eugeniy Fedirets , 2017 9 | Alexandre Prokoudine , 2017 10 | 11 | uk 12 | Eugeniy Fedirets , 2017 13 | 14 | zh_CN 15 | Senlin 16 | -------------------------------------------------------------------------------- /desktop/azpainter.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | AzPainter File 5 | AzPainter ファイル 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /NEWS: -------------------------------------------------------------------------------- 1 | # ver 2.1.0 (2017/08/26) 2 | 追加、変更、修正 3 | 4 | # ver 2.0.6 (2017/06/03) 5 | GUI 関連の設定追加など 6 | 7 | # ver 2.0.5 (2017/05/20) 8 | 追加、変更、修正 9 | 10 | # ver 2.0.4 (2017/03/11) 11 | 修正 12 | 13 | # ver 2.0.3 (2017/03/05) 14 | 追加、変更、修正 15 | 16 | # ver 2.0.2 (2017/02/19) 17 | 追加、変更、修正 18 | 19 | # ver 2.0.1 (2017/02/07) 20 | アイコンファイル修正 21 | 22 | # ver 2.0.0 (2017/02/04) 23 | 作り直し 24 | 25 | # ver 1.0.7 (2016/02/03) 26 | ver 1.x 最終版 27 | 28 | # ver 1.0.0 (2013/12/21) 29 | 初期リリース 30 | -------------------------------------------------------------------------------- /data/theme/black.theme: -------------------------------------------------------------------------------- 1 | [color] 2 | face=3c3f41 3 | face_focus=324761 4 | face_select=2f65ca 5 | face_select_light=244d98 6 | face_dark=4f5557 7 | face_darker=303233 8 | face_lightest=45494a 9 | frame=5e5f60 10 | frame_focus=575d65 11 | frame_dark=2f3334 12 | frame_light=4f4f4f 13 | text=bbbbbb 14 | text_reverse=bbbbbb 15 | text_disable=5e6061 16 | text_select=bbbbbb 17 | menu_face=3c3f41 18 | menu_frame=9a9a9a 19 | menu_sep=656769 20 | menu_select=3679d0 21 | menu_text=bbbbbb 22 | menu_text_disable=5e6061 23 | menu_text_shortcut=989898 24 | iconbtt_face_select=ffdfb1 25 | iconbtt_frame_select=e59523 26 | -------------------------------------------------------------------------------- /desktop/Makefile.am: -------------------------------------------------------------------------------- 1 | EXTRA_DIST = azpainter.desktop azpainter.png azpainter.svg \ 2 | application-x-azpainter-apd.png application-x-azpainter-apd.svg azpainter.xml 3 | 4 | desktopdir = $(datadir)/applications 5 | desktop_DATA = azpainter.desktop 6 | 7 | icondir = $(datadir)/icons/hicolor/48x48/apps 8 | icon_DATA = azpainter.png application-x-azpainter-apd.png 9 | 10 | svgdir = $(datadir)/icons/hicolor/scalable/apps 11 | svg_DATA = azpainter.svg application-x-azpainter-apd.svg 12 | 13 | mimetypedir = $(datadir)/mime/packages 14 | mimetype_DATA = azpainter.xml 15 | 16 | ### rule 17 | 18 | install-data-hook: update-cache 19 | uninstall-hook: update-cache 20 | 21 | update-cache: 22 | @-if test -z "$(DESTDIR)"; then \ 23 | echo "* Updating cache."; \ 24 | gtk-update-icon-cache -f -t $(datadir)/icons/hicolor; \ 25 | update-mime-database $(datadir)/mime; \ 26 | update-desktop-database $(datadir)/applications; \ 27 | fi 28 | -------------------------------------------------------------------------------- /src/include/defDrawGlobal.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | #ifndef DEF_DRAW_GLOBAL 21 | #define DEF_DRAW_GLOBAL 22 | 23 | typedef struct _DrawData DrawData; 24 | 25 | extern DrawData *g_app_draw; 26 | #define APP_DRAW g_app_draw 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /src/include/AppResource.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | #ifndef APP_RESOURCE_H 21 | #define APP_RESOURCE_H 22 | 23 | #define APP_RESOURCE_TOOLBAR_ICON_NUM 16 24 | 25 | mImageList *AppResource_loadIconImage(const char *filename,int size); 26 | 27 | const uint8_t *AppResource_getToolbarBtt_default(); 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /src/include/PopupThread.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************** 21 | * ポップアップの進捗表示付きスレッド 22 | **************************************/ 23 | 24 | #ifndef POPUP_THREAD_H 25 | #define POPUP_THREAD_H 26 | 27 | #include "mPopupProgress.h" 28 | 29 | int PopupThread_run(void *data,int (*func)(mPopupProgress *,void *)); 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /src/include/SinTable.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************** 21 | * sin テーブル 22 | ***************************/ 23 | 24 | #ifndef SINTABLE_H 25 | #define SINTABLE_H 26 | 27 | extern float g_sintable[512]; 28 | 29 | void SinTable_init(); 30 | 31 | #define SINTABLE_GETSIN(n) g_sintable[n & 511] 32 | #define SINTABLE_GETCOS(n) g_sintable[(n + 128) & 511] 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /src/include/PrevCursor.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************* 21 | * カーソル画像プレビューウィジェット 22 | *************************************/ 23 | 24 | #ifndef PREV_CURSOR_H 25 | #define PREV_CURSOR_H 26 | 27 | typedef struct _PrevCursor PrevCursor; 28 | 29 | PrevCursor *PrevCursor_new(mWidget *parent); 30 | void PrevCursor_setBuf(PrevCursor *p,uint8_t *buf); 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /src/include/EnvOptDlg.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | #ifndef ENVOPTDLG_H 21 | #define ENVOPTDLG_H 22 | 23 | int EnvOptionDlg_run(mWindow *owner); 24 | 25 | enum 26 | { 27 | ENVOPTDLG_F_UPDATE_CANVAS = 1<<0, 28 | ENVOPTDLG_F_UPDATE_ALL = 1<<1, 29 | ENVOPTDLG_F_CURSOR = 1<<2, 30 | ENVOPTDLG_F_ICONSIZE = 1<<3, 31 | ENVOPTDLG_F_TOOLBAR_BTT = 1<<4, 32 | ENVOPTDLG_F_THEME = 1<<5 33 | }; 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /src/widget/PopupSliderZoom.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*********************************** 21 | * 倍率変更用ポップアップスライダー 22 | ***********************************/ 23 | 24 | #ifndef POPUPSLIDERZOOM_H 25 | #define POPUPSLIDERZOOM_H 26 | 27 | int PopupSliderZoom_run(int rootx,int rooty, 28 | int min,int max,int current,int step_low,int step_hi, 29 | void (*handle)(int,void *),void *param); 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /src/include/FileDialog.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * ファイル選択ダイアログ 22 | ************************************/ 23 | 24 | #ifndef FILEDIALOG_H 25 | #define FILEDIALOG_H 26 | 27 | #define FILEDIALOG_LAYERIMAGE_IS_IGNORE_ALPHA(n) (((n) & 1) != 0) 28 | 29 | int FileDialog_openLayerImage(mWindow *owner,const char *filter,const char *initdir,mStr *strfname); 30 | 31 | #endif 32 | -------------------------------------------------------------------------------- /src/include/draw_text.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************** 21 | * テキスト描画処理関数 22 | *****************************/ 23 | 24 | #ifndef DRAW_DRAWTEXT_H 25 | #define DRAW_DRAWTEXT_H 26 | 27 | void drawText_createFont(); 28 | void drawText_setHinting(DrawData *p); 29 | 30 | void drawText_drawPreview(DrawData *p); 31 | void drawText_setDrawPoint_inDialog(DrawData *p,int x,int y); 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /src/include/StatusBar.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * ステータスバー 関数 22 | ************************************/ 23 | 24 | #ifndef STATUSBAR_H 25 | #define STATUSBAR_H 26 | 27 | void StatusBar_new(); 28 | void StatusBar_toggleVisible(); 29 | mBool StatusBar_getProgressBarPos(mPoint *pt); 30 | 31 | void StatusBar_setImageInfo(); 32 | void StatusBar_setHelp_tool(); 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /src/other/SinTable.c: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************************** 21 | * Sin テーブル 22 | *****************************************/ 23 | 24 | #include 25 | 26 | 27 | float g_sintable[512]; 28 | 29 | 30 | /** テーブル初期化 */ 31 | 32 | void SinTable_init() 33 | { 34 | int i; 35 | 36 | for(i = 0; i < 512; i++) 37 | g_sintable[i] = (float)sin(i / 256.0 * 3.14159265358979323846); 38 | } 39 | -------------------------------------------------------------------------------- /src/include/draw_boxedit.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * DrawData 矩形編集 22 | **********************************/ 23 | 24 | #ifndef DRAW_BOXEDIT_H 25 | #define DRAW_BOXEDIT_H 26 | 27 | void drawBoxEdit_clear_noupdate(DrawData *p); 28 | void drawBoxEdit_restoreCursor(DrawData *p); 29 | void drawBoxEdit_setBox(DrawData *p,mRect *rcsel); 30 | 31 | void drawBoxEdit_run(DrawData *p,int type); 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /src/include/defScalingType.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 拡大縮小補間方法 22 | ************************************/ 23 | 24 | #ifndef DEF_SCALING_TYPE_H 25 | #define DEF_SCALING_TYPE_H 26 | 27 | enum 28 | { 29 | SCALING_TYPE_NEAREST_NEIGHBOR, 30 | SCALING_TYPE_MITCHELL, 31 | SCALING_TYPE_LANGRANGE, 32 | SCALING_TYPE_LANCZOS2, 33 | SCALING_TYPE_LANCZOS3, 34 | 35 | SCALING_TYPE_NUM 36 | }; 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /src/include/trid_word.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************** 21 | * 翻訳文字列ID : 単語 22 | *****************************/ 23 | 24 | #ifndef TRID_WORD_H 25 | #define TRID_WORD_H 26 | 27 | enum 28 | { 29 | TRID_WORD_WIDTH, 30 | TRID_WORD_HEIGHT, 31 | TRID_WORD_COLOR, 32 | TRID_WORD_DENSITY, 33 | TRID_WORD_PIXELMODE, 34 | TRID_WORD_ANTIALIAS, 35 | TRID_WORD_FOLDER, 36 | TRID_WORD_LAYER, 37 | TRID_WORD_NAME 38 | }; 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /src/include/trid_message.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************** 21 | * 翻訳文字列ID : メッセージ 22 | *****************************/ 23 | 24 | #ifndef TRID_MESSAGE_H 25 | #define TRID_MESSAGE_H 26 | 27 | enum 28 | { 29 | TRID_MES_SAVE_OVERWRITE = 0, 30 | TRID_MES_SAVE_APD, 31 | TRID_MES_SAVE_CONFIRM, 32 | TRID_MES_EMPTY_TEMPDIR, 33 | TRID_MES_CONVERT_VER1, 34 | TRID_MES_RECENTFILE_NOTEXIST, 35 | TRID_MES_IMAGESIZE_LIMIT 36 | }; 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /src/filter/PerlinNoise.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * PerlinNoise 生成 22 | ***************************************/ 23 | 24 | #ifndef PERLIN_NOISE_H 25 | #define PERLIN_NOISE_H 26 | 27 | typedef struct _PerlinNoise PerlinNoise; 28 | 29 | PerlinNoise *PerlinNoise_new(double freq,double persis); 30 | void PerlinNoise_free(PerlinNoise *p); 31 | 32 | double PerlinNoise_getNoise(PerlinNoise *p,double x,double y); 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /src/include/PrevImage8.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************** 21 | * ImageBuf8 のプレビューウィジェット 22 | **************************************/ 23 | 24 | #ifndef PREVIMAGE8_H 25 | #define PREVIMAGE8_H 26 | 27 | typedef struct _PrevImage8 PrevImage8; 28 | typedef struct _ImageBuf8 ImageBuf8; 29 | 30 | PrevImage8 *PrevImage8_new(mWidget *parent,int hintw,int hinth,uint32_t fLayout); 31 | void PrevImage8_setImage(PrevImage8 *p,ImageBuf8 *img,mBool bBrush); 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /src/widget/PressureWidget.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 筆圧操作ウィジェット 22 | ************************************/ 23 | 24 | #ifndef PRESSURE_WIDGET_H 25 | #define PRESSURE_WIDGET_H 26 | 27 | typedef struct _PressureWidget PressureWidget; 28 | 29 | 30 | PressureWidget *PressureWidget_new(mWidget *parent,int id); 31 | 32 | void PressureWidget_setValue(PressureWidget *p,int type,uint32_t val); 33 | uint32_t PressureWidget_getValue(PressureWidget *p); 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /src/include/ConfigData.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * ConfigData 関数 22 | ************************************/ 23 | 24 | #ifndef CONFIGDATA_H 25 | #define CONFIGDATA_H 26 | 27 | mBool ConfigData_new(); 28 | void ConfigData_free(); 29 | 30 | void ConfigData_setTempDir_default(); 31 | void ConfigData_createTempDir(); 32 | void ConfigData_deleteTempDir(); 33 | 34 | mBool ConfigData_getTempPath(mStr *str,const char *add); 35 | 36 | void ConfigData_waterPreset_default(); 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /src/include/PrevTileImage.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * TileImage プレビューウィジェット 22 | **********************************/ 23 | 24 | #ifndef PREV_TILEIMAGE_H 25 | #define PREV_TILEIMAGE_H 26 | 27 | typedef struct _PrevTileImage PrevTileImage; 28 | typedef struct _TileImage TileImage; 29 | 30 | PrevTileImage *PrevTileImage_new(mWidget *parent,int w,int h,int (*dnd_handle)(mWidget *,char **)); 31 | void PrevTileImage_setImage(PrevTileImage *p,TileImage *img,int w,int h); 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /src/include/draw_op_main.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * DrawData 操作のメイン関数 22 | **********************************/ 23 | 24 | #ifndef DRAW_OP_MAIN_H 25 | #define DRAW_OP_MAIN_H 26 | 27 | mBool drawOp_onPress(DrawData *p,mEvent *ev); 28 | mBool drawOp_onRelease(DrawData *p,mEvent *ev); 29 | void drawOp_onMotion(DrawData *p,mEvent *ev); 30 | mBool drawOp_onLBttDblClk(DrawData *p,mEvent *ev); 31 | mBool drawOp_onKeyDown(DrawData *p,uint32_t key); 32 | void drawOp_onUngrab(DrawData *p); 33 | 34 | #endif 35 | -------------------------------------------------------------------------------- /src/include/ColorWheel.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | #ifndef COLORWHEEL_H 21 | #define COLORWHEEL_H 22 | 23 | typedef struct _ColorWheel ColorWheel; 24 | 25 | enum 26 | { 27 | COLORWHEEL_TYPE_HSV_TRIANGLE, 28 | COLORWHEEL_TYPE_HSV_RECTANGLE 29 | }; 30 | 31 | enum 32 | { 33 | COLORWHEEL_N_CHANGE_COL, 34 | COLORWHEEL_N_CHANGE_TYPE 35 | }; 36 | 37 | ColorWheel *ColorWheel_new(mWidget *parent,int id,int type,uint32_t col); 38 | void ColorWheel_setColor(ColorWheel *p,int col,mBool hsv); 39 | void ColorWheel_redraw(ColorWheel *p); 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /src/include/FilterPrev.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * フィルタ、ダイアログ中のプレビュー 22 | ************************************/ 23 | 24 | #ifndef FILTERPREV_H 25 | #define FILTERPREV_H 26 | 27 | typedef struct _FilterPrev FilterPrev; 28 | typedef struct _TileImage TileImage; 29 | 30 | FilterPrev *FilterPrev_new(mWidget *parent,int id,int w,int h,TileImage *imgsrc,int fullw,int fullh); 31 | 32 | void FilterPrev_getDrawArea(FilterPrev *p,mRect *rc,mBox *box); 33 | void FilterPrev_drawImage(FilterPrev *p,TileImage *img); 34 | 35 | #endif 36 | -------------------------------------------------------------------------------- /mlib/src/x11/x11_img_cursor.h: -------------------------------------------------------------------------------- 1 | //水平分割 2 | static unsigned char g_cur_hsplit[] = { 3 | 19, 15, 9, 7, 4 | 0x00, 0x00, 0x00, 0x80, 0x0d, 0x00, 0x80, 0x0d, 0x00, 0x80, 0x0d, 0x00, 5 | 0x90, 0x4d, 0x00, 0x98, 0xcd, 0x00, 0x9c, 0xcd, 0x01, 0xfe, 0xfd, 0x03, 6 | 0x9c, 0xcd, 0x01, 0x98, 0xcd, 0x00, 0x90, 0x4d, 0x00, 0x80, 0x0d, 0x00, 7 | 0x80, 0x0d, 0x00, 0x80, 0x0d, 0x00, 0x00, 0x00, 0x00, 8 | // 9 | 0xc0, 0x1f, 0x00, 0xc0, 0x1f, 0x00, 0xc0, 0x1f, 0x00, 0xd0, 0x5f, 0x00, 10 | 0xf8, 0xff, 0x00, 0xfc, 0xff, 0x01, 0xfe, 0xff, 0x03, 0xff, 0xff, 0x07, 11 | 0xfe, 0xff, 0x03, 0xfc, 0xff, 0x01, 0xf8, 0xff, 0x00, 0xd0, 0x5f, 0x00, 12 | 0xc0, 0x1f, 0x00, 0xc0, 0x1f, 0x00, 0xc0, 0x1f, 0x00 }; 13 | 14 | //垂直分割 15 | static unsigned char g_cur_vsplit[] = { 16 | 15, 19, 7, 9, 17 | 0x00, 0x00, 0x80, 0x00, 0xc0, 0x01, 0xe0, 0x03, 0xf0, 0x07, 0xc0, 0x01, 18 | 0xc0, 0x01, 0xfe, 0x3f, 0xfe, 0x3f, 0x00, 0x00, 0xfe, 0x3f, 0xfe, 0x3f, 19 | 0xc0, 0x01, 0xc0, 0x01, 0xf0, 0x07, 0xe0, 0x03, 0xc0, 0x01, 0x80, 0x00, 20 | 0x00, 0x00, 21 | // 22 | 0x80, 0x00, 0xc0, 0x01, 0xe0, 0x03, 0xf0, 0x07, 0xf8, 0x0f, 0xf0, 0x07, 23 | 0xff, 0x7f, 0xff, 0x7f, 0xff, 0x7f, 0xff, 0x7f, 0xff, 0x7f, 0xff, 0x7f, 24 | 0xff, 0x7f, 0xf0, 0x07, 0xf8, 0x0f, 0xf0, 0x07, 0xe0, 0x03, 0xc0, 0x01, 25 | 0x80, 0x00 }; 26 | -------------------------------------------------------------------------------- /src/include/CanvasDialogs.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * キャンバス関連ダイアログ 22 | ************************************/ 23 | 24 | #ifndef CANVAS_DIALOGS_H 25 | #define CANVAS_DIALOGS_H 26 | 27 | typedef struct 28 | { 29 | int w,h,align; 30 | mBool crop; 31 | }CanvasResizeInfo; 32 | 33 | typedef struct 34 | { 35 | int w,h,dpi,type; 36 | mBool have_dpi; //DPI変更の項目を付けるか 37 | }CanvasScaleInfo; 38 | 39 | mBool CanvasResizeDlg_run(mWindow *owner,CanvasResizeInfo *info); 40 | mBool CanvasScaleDlg_run(mWindow *owner,CanvasScaleInfo *info); 41 | 42 | #endif 43 | -------------------------------------------------------------------------------- /src/include/BrushSizeList.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************** 21 | * ブラシサイズリストデータ 22 | ********************************/ 23 | 24 | #ifndef BRUSHSIZELIST_H 25 | #define BRUSHSIZELIST_H 26 | 27 | void BrushSizeList_init(); 28 | void BrushSizeList_free(); 29 | 30 | mBool BrushSizeList_alloc(int num); 31 | void BrushSizeList_setNum(int num); 32 | 33 | int BrushSizeList_getNum(); 34 | uint16_t *BrushSizeList_getBuf(); 35 | int BrushSizeList_getValue(int pos); 36 | 37 | void BrushSizeList_addFromText(const char *text); 38 | void BrushSizeList_deleteAtPos(int pos); 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /src/include/FilterSaveData.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * フィルタのデータ保存管理 22 | ***************************************/ 23 | 24 | #ifndef FILTER_SAVE_DATA_H 25 | #define FILTER_SAVE_DATA_H 26 | 27 | typedef struct _mIniRead mIniRead; 28 | 29 | void FilterSaveData_free(); 30 | 31 | void FilterSaveData_getConfig(mIniRead *ini); 32 | void FilterSaveData_setConfig(void *fp_ptr); 33 | 34 | char *FilterSaveData_getText(int cmdid); 35 | mBool FilterSaveData_getValue(char *text,char id,int *dst); 36 | void FilterSaveData_setData(int cmdid,const char *text); 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /src/include/SelMaterial.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 素材画像の選択バー ウィジェット 22 | ************************************/ 23 | 24 | #ifndef SELMATERIAL_H 25 | #define SELMATERIAL_H 26 | 27 | typedef struct _SelMaterial SelMaterial; 28 | 29 | enum 30 | { 31 | SELMATERIAL_TYPE_TEXTURE, 32 | SELMATERIAL_TYPE_BRUSH_TEXTURE, 33 | SELMATERIAL_TYPE_BRUSH_SHAPE 34 | }; 35 | 36 | SelMaterial *SelMaterial_new(mWidget *parent,int id,int type); 37 | void SelMaterial_setName(SelMaterial *p,const char *name); 38 | void SelMaterial_getName(SelMaterial *p,mStr *str); 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /src/include/FilterBar.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * フィルタダイアログ用の数値バー 22 | ************************************/ 23 | 24 | #ifndef FILTERBAR_H 25 | #define FILTERBAR_H 26 | 27 | typedef struct _FilterBar FilterBar; 28 | 29 | #define FILTERBAR(p) ((FilterBar *)(p)) 30 | 31 | 32 | FilterBar *FilterBar_new(mWidget *parent,int id,uint32_t fLayout,int initw, 33 | int min,int max,int pos,int center); 34 | 35 | int FilterBar_getPos(FilterBar *p); 36 | mBool FilterBar_setPos(FilterBar *p,int pos); 37 | void FilterBar_setStatus(FilterBar *p,int min,int max,int pos); 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /src/include/AppErr.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * アプリケーションエラー番号 22 | * 23 | * (翻訳データの文字列IDと連動している) 24 | ***************************************/ 25 | 26 | #ifndef APPERR_H 27 | #define APPERR_H 28 | 29 | enum 30 | { 31 | APPERR_OK, 32 | APPERR_FAILED, 33 | APPERR_ALLOC, 34 | APPERR_UNSUPPORTED_FORMAT, 35 | APPERR_LOAD, 36 | APPERR_LARGE_SIZE, 37 | APPERR_LOAD_ONLY_APDv3, 38 | APPERR_USED_KEY, 39 | APPERR_CANNOTDRAW_FOLDER, 40 | APPERR_CANNOTDRAW_LOCK, 41 | APPERR_NONE_CHECKED_LAYER, 42 | APPERR_NONE_OPT_TEXTURE, 43 | APPERR_FILTER_COLTYPE 44 | }; 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /src/include/SplineBuf.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************* 21 | * スプラインのポイントバッファ 22 | *******************************/ 23 | 24 | #ifndef SPLINE_BUF_H 25 | #define SPLINE_BUF_H 26 | 27 | void SplineBuf_init(); 28 | void SplineBuf_free(); 29 | 30 | mBool SplineBuf_start(); 31 | 32 | mBool SplineBuf_addPoint(mPoint *pt,uint8_t pressure); 33 | mBool SplineBuf_deleteLastPoint(mPoint *ptlast); 34 | void SplineBuf_scrollPoint(mPoint *pt); 35 | 36 | void SplineBuf_beginGetPoint(); 37 | int SplineBuf_getPoint(mPoint *pt); 38 | 39 | mBool SplineBuf_initDraw(); 40 | mBool SplineBuf_getNextDraw(mDoublePoint *pt,uint8_t *pressure); 41 | 42 | #endif 43 | -------------------------------------------------------------------------------- /src/include/ValueBar.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * スピン、小数部つきの数値選択バー 22 | ************************************/ 23 | 24 | #ifndef VALUEBAR_H 25 | #define VALUEBAR_H 26 | 27 | typedef struct _ValueBar ValueBar; 28 | 29 | #define VALUEBAR(p) ((ValueBar *)(p)) 30 | 31 | 32 | ValueBar *ValueBar_new(mWidget *parent,int id,uint32_t fLayout, 33 | int dig,int min,int max,int pos); 34 | 35 | int ValueBar_getPos(ValueBar *p); 36 | mBool ValueBar_setPos(ValueBar *p,int pos); 37 | void ValueBar_setStatus(ValueBar *p,int min,int max,int pos); 38 | void ValueBar_setStatus_dig(ValueBar *p,int dig,int min,int max,int pos); 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /src/include/defBlendMode.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * 合成モード定義 22 | ***************************************/ 23 | 24 | #ifndef DEF_BLENDMODE_H 25 | #define DEF_BLENDMODE_H 26 | 27 | enum 28 | { 29 | BLENDMODE_NORMAL, 30 | BLENDMODE_MUL, 31 | BLENDMODE_ADD, 32 | BLENDMODE_SUB, 33 | BLENDMODE_SCREEN, 34 | BLENDMODE_OVERLAY, 35 | BLENDMODE_HARD_LIGHT, 36 | BLENDMODE_SOFT_LIGHT, 37 | BLENDMODE_DODGE, 38 | BLENDMODE_BURN, 39 | BLENDMODE_LINEAR_BURN, 40 | BLENDMODE_VIVID_LIGHT, 41 | BLENDMODE_LINEAR_LIGHT, 42 | BLENDMODE_PIN_LIGHT, 43 | BLENDMODE_DARK, 44 | BLENDMODE_LIGHT, 45 | BLENDMODE_DIFF, 46 | 47 | BLENDMODE_NUM 48 | }; 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /data/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS=texture 2 | 3 | appdatadir=$(datadir)/azpainter 4 | 5 | dist_appdata_DATA=\ 6 | palette-2.dat \ 7 | brush-2.dat \ 8 | grad.dat \ 9 | sckey-2.conf \ 10 | icon.png 11 | 12 | # tr 13 | 14 | trdatadir=$(appdatadir)/tr 15 | 16 | dist_trdata_DATA=\ 17 | tr/en.mtr \ 18 | tr/ja.mtr \ 19 | tr/pt_BR.mtr \ 20 | tr/ru.mtr \ 21 | tr/uk.mtr \ 22 | tr/zh_CN.mtr 23 | 24 | # theme 25 | 26 | themedir=$(appdatadir)/theme 27 | dist_theme_DATA=theme/black.theme 28 | 29 | # image 30 | 31 | img13dir=$(appdatadir)/13x13 32 | img16dir=$(appdatadir)/16x16 33 | img20dir=$(appdatadir)/20x20 34 | img24dir=$(appdatadir)/24x24 35 | 36 | dist_img13_DATA=13x13/layer.png 37 | 38 | dist_img16_DATA=\ 39 | 16x16/brushedit.png \ 40 | 16x16/canvasview.png \ 41 | 16x16/imgviewer.png \ 42 | 16x16/layer.png \ 43 | 16x16/tool.png \ 44 | 16x16/toolbar.png \ 45 | 16x16/toolsub.png 46 | 47 | dist_img20_DATA=\ 48 | 20x20/brushedit.png \ 49 | 20x20/canvasview.png \ 50 | 20x20/imgviewer.png \ 51 | 20x20/tool.png \ 52 | 20x20/toolbar.png \ 53 | 20x20/toolsub.png 54 | 55 | dist_img24_DATA=\ 56 | 24x24/brushedit.png \ 57 | 24x24/canvasview.png \ 58 | 24x24/imgviewer.png \ 59 | 24x24/tool.png \ 60 | 24x24/toolbar.png \ 61 | 24x24/toolsub.png 62 | 63 | # brush 64 | 65 | brushdir=$(appdatadir)/brush 66 | 67 | dist_brush_DATA=\ 68 | brush/circle1.png \ 69 | brush/ellipse.png 70 | 71 | # uninstall 72 | 73 | uninstall-local: 74 | -test -d "$(appdatadir)" && rm -rf "$(appdatadir)" 75 | -------------------------------------------------------------------------------- /src/include/draw_select.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * DrawData 選択範囲関連 22 | **********************************/ 23 | 24 | #ifndef DRAW_SELECT_H 25 | #define DRAW_SELECT_H 26 | 27 | mBool drawSel_isHave(); 28 | void drawSel_release(DrawData *p,mBool update); 29 | 30 | void drawSel_inverse(DrawData *p); 31 | void drawSel_all(DrawData *p); 32 | void drawSel_fill_erase(DrawData *p,mBool erase); 33 | void drawSel_copy_cut(DrawData *p,mBool cut); 34 | void drawSel_paste_newlayer(DrawData *p); 35 | void drawSel_expand(DrawData *p,int cnt); 36 | 37 | void drawSel_getFullDrawRect(DrawData *p,mRect *rc); 38 | mBool drawSel_createImage(DrawData *p); 39 | void drawSel_freeEmpty(DrawData *p); 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /src/include/MaterialImgList.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 素材画像管理リスト 22 | ************************************/ 23 | 24 | #ifndef MATERIALIMGLIST_H 25 | #define MATERIALIMGLIST_H 26 | 27 | typedef struct _ImageBuf8 ImageBuf8; 28 | 29 | enum 30 | { 31 | MATERIALIMGLIST_TYPE_LAYER_TEXTURE = 0, 32 | MATERIALIMGLIST_TYPE_BRUSH_TEXTURE, 33 | MATERIALIMGLIST_TYPE_BRUSH_SHAPE, 34 | 35 | MATERIALIMGLIST_TYPE_TEXTURE = 0, 36 | MATERIALIMGLIST_TYPE_BRUSH 37 | }; 38 | 39 | 40 | void MaterialImgList_init(); 41 | void MaterialImgList_free(); 42 | 43 | ImageBuf8 *MaterialImgList_getImage(int type,const char *path,mBool keep); 44 | void MaterialImgList_releaseImage(int type,ImageBuf8 *img); 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /src/include/DrawFill.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************* 21 | * 塗りつぶし描画処理 22 | *******************************/ 23 | 24 | #ifndef DRAWFILL_H 25 | #define DRAWFILL_H 26 | 27 | typedef struct _DrawFill DrawFill; 28 | typedef struct _TileImage TileImage; 29 | typedef union _RGBAFix15 RGBAFix15; 30 | 31 | enum 32 | { 33 | DRAWFILL_TYPE_RGB, 34 | DRAWFILL_TYPE_ALPHA, 35 | DRAWFILL_TYPE_AUTO_ANTIALIAS, 36 | DRAWFILL_TYPE_CANVAS, 37 | DRAWFILL_TYPE_OPAQUE = 100 38 | }; 39 | 40 | 41 | DrawFill *DrawFill_new(TileImage *imgdst,TileImage *imgref,mPoint *ptstart, 42 | int type,int color_diff,int draw_opacity); 43 | 44 | void DrawFill_free(DrawFill *p); 45 | 46 | void DrawFill_run(DrawFill *p,RGBAFix15 *pixdraw); 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /src/include/FilterDefWidget.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * フィルタの定義ウィジェット 22 | ***************************************/ 23 | 24 | #ifndef FILTER_DEF_WIDGET_H 25 | #define FILTER_DEF_WIDGET_H 26 | 27 | /* レベル補正 */ 28 | 29 | typedef struct _FilterWgLevel FilterWgLevel; 30 | 31 | FilterWgLevel *FilterWgLevel_new(mWidget *parent,int id,uint32_t *histogram); 32 | void FilterWgLevel_getValue(FilterWgLevel *p,int *buf); 33 | 34 | /* 色置き換え */ 35 | 36 | typedef struct _FilterWgRepcol FilterWgRepcol; 37 | 38 | #define FILTERWGREPCOL_N_UPDATE_PREV 0 39 | #define FILTERWGREPCOL_N_CHANGE_EDIT 1 40 | 41 | FilterWgRepcol *FilterWgRepcol_new(mWidget *parent,int id,uint32_t drawcol); 42 | void FilterWgRepcol_getColor(FilterWgRepcol *p,int *dst); 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /src/include/draw_rule.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * DrawData 定規関連 22 | **********************************/ 23 | 24 | #ifndef DRAW_RULE_H 25 | #define DRAW_RULE_H 26 | 27 | enum 28 | { 29 | RULE_TYPE_OFF, 30 | RULE_TYPE_PARALLEL_LINE, 31 | RULE_TYPE_GRID_LINE, 32 | RULE_TYPE_CONC_LINE, 33 | RULE_TYPE_CIRCLE, 34 | RULE_TYPE_ELLIPSE, 35 | 36 | RULE_TYPE_NUM 37 | }; 38 | 39 | 40 | void drawRule_setType(DrawData *p,int type); 41 | void drawRule_onPress(DrawData *p,mBool dotpen); 42 | mBool drawRule_onPress_setting(DrawData *p); 43 | 44 | void drawRule_setting_line(DrawData *p); 45 | void drawRule_setting_ellipse(DrawData *p); 46 | 47 | void drawRule_setRecord(DrawData *p,int no); 48 | void drawRule_callRecord(DrawData *p,int no); 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /src/include/defTileImage.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************** 21 | * TileImage 本体の定義 22 | *****************************/ 23 | 24 | #ifndef DEF_TILEIMAGE_H 25 | #define DEF_TILEIMAGE_H 26 | 27 | #include "ColorValue.h" 28 | 29 | typedef struct _TileImage TileImage; 30 | 31 | struct _TileImage 32 | { 33 | uint8_t **ppbuf; //タイル配列 34 | TileImage *link; //リンク (塗りつぶし時など) 35 | int coltype, //カラータイプ 36 | tilesize, //1つのタイルのバイト数 37 | tilew,tileh, //タイル配列の幅と高さ 38 | offx,offy; //オフセット位置 39 | RGBFix15 rgb; //線の色 40 | }; 41 | 42 | 43 | #define TILEIMAGE_TILE_EMPTY ((uint8_t *)1) 44 | 45 | #define TILEIMAGE_GETTILE_BUFPT(p,tx,ty) ((p)->ppbuf + (ty) * (p)->tilew + (tx)) 46 | #define TILEIMAGE_GETTILE_PT(p,tx,ty) *((p)->ppbuf + (ty) * (p)->tilew + (tx)) 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /src/include/DrawFont.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************** 21 | * テキスト描画用フォント 22 | ***************************/ 23 | 24 | #ifndef DRAWFONT_H 25 | #define DRAWFONT_H 26 | 27 | typedef struct _DrawFont DrawFont; 28 | typedef struct _mFontInfo mFontInfo; 29 | 30 | 31 | typedef struct 32 | { 33 | int char_space, 34 | line_space, 35 | flags; 36 | void (*setpixel)(int,int,int,void *); 37 | void *param; 38 | }DrawFontInfo; 39 | 40 | enum 41 | { 42 | DRAWFONT_F_VERT = 1<<0 43 | }; 44 | 45 | 46 | mBool DrawFont_init(); 47 | void DrawFont_finish(); 48 | 49 | void DrawFont_free(DrawFont *p); 50 | DrawFont *DrawFont_create(mFontInfo *info); 51 | 52 | void DrawFont_setHinting(DrawFont *p,int type); 53 | 54 | void DrawFont_drawText(DrawFont *p,int x,int y,const char *text,DrawFontInfo *info); 55 | 56 | #endif 57 | -------------------------------------------------------------------------------- /BSD: -------------------------------------------------------------------------------- 1 | Copyright (c) 2017, Azel 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are met: 6 | * Redistributions of source code must retain the above copyright 7 | notice, this list of conditions and the following disclaimer. 8 | * Redistributions in binary form must reproduce the above copyright 9 | notice, this list of conditions and the following disclaimer in the 10 | documentation and/or other materials provided with the distribution. 11 | * Neither the name of the nor the 12 | names of its contributors may be used to endorse or promote products 13 | derived from this software without specific prior written permission. 14 | 15 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 16 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 17 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 18 | DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY 19 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 20 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 21 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 22 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 24 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 | -------------------------------------------------------------------------------- /src/include/defLoadErr.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * 読み込みエラー文字列 22 | ***************************************/ 23 | 24 | #ifndef DEF_LOADERR_H 25 | #define DEF_LOADERR_H 26 | 27 | enum 28 | { 29 | LOADERR_OK = -1, 30 | LOADERR_ALLOC = 0, 31 | LOADERR_CORRUPTED, 32 | LOADERR_OPENFILE, 33 | LOADERR_HEADER, 34 | LOADERR_VERSION, 35 | LOADERR_INVALID_VALUE, 36 | LOADERR_DECODE, 37 | 38 | LOADERR_NUM 39 | }; 40 | 41 | /*-----------*/ 42 | 43 | #ifdef LOADERR_DEFINE 44 | 45 | const char *g_loaderr_str[] = { 46 | "memory alloc error", 47 | "corrupted file", 48 | "open error", 49 | "invalid header", 50 | "version error", 51 | "invalid value", 52 | "decode error" 53 | }; 54 | 55 | #else 56 | 57 | extern const char *g_loaderr_str[LOADERR_NUM]; 58 | 59 | #endif 60 | 61 | #endif 62 | -------------------------------------------------------------------------------- /src/include/PixbufDraw.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * mPixbuf 描画関数 22 | ************************************/ 23 | 24 | #ifndef PIXBUFDRAW_H 25 | #define PIXBUFDRAW_H 26 | 27 | typedef struct _CanvasDrawInfo CanvasDrawInfo; 28 | 29 | void pixbufDraw_cross_dash(mPixbuf *pixbuf,int x,int y,int size,mBox *box); 30 | void pixbufDraw_dashBox_mono(mPixbuf *pixbuf,int x,int y,int w,int h); 31 | 32 | void pixbufDrawGrid(mPixbuf *p,mBox *boxdst,mBox *boximg, 33 | int gridw,int gridh,uint32_t col,CanvasDrawInfo *info); 34 | 35 | void pixbufDraw_setPixelSelectEdge(mPixbuf *pixbuf,int x,int y,mRect *rcclip); 36 | void pixbufDraw_lineSelectEdge(mPixbuf *pixbuf,int x1,int y1,int x2,int y2,mRect *rcclip); 37 | 38 | void pixbufDrawBoxEditFrame(mPixbuf *pixbuf,mBox *boximg,CanvasDrawInfo *info); 39 | 40 | #endif 41 | -------------------------------------------------------------------------------- /src/include/defMacros.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************** 21 | * 共通マクロ定義 22 | **********************/ 23 | 24 | #ifndef DEF_MACROS_H 25 | #define DEF_MACROS_H 26 | 27 | #define APPNAME "AzPainter" 28 | 29 | #define IMAGE_SIZE_MAX 20000 //イメージ最大サイズ 30 | #define CANVAS_ZOOM_MIN 10 //キャンバス表示倍率、最小 (1%=10) 31 | #define CANVAS_ZOOM_MAX 10000 32 | 33 | #define FILEFILTER_NORMAL_IMAGE "Image File (BMP/PNG/GIF/JPEG)\t*.bmp;*.png;*.gif;*.jpg;*.jpeg\tAll Files (*)\t*\t" 34 | 35 | #define CONFIG_FILENAME_MAIN "main-2.conf" 36 | #define CONFIG_FILENAME_BRUSH "brush-2.dat" 37 | #define CONFIG_FILENAME_COLPALETTE "palette-2.dat" 38 | #define CONFIG_FILENAME_GRADATION "grad.dat" 39 | #define CONFIG_FILENAME_SHORTCUTKEY "sckey-2.conf" 40 | 41 | #define APP_TEXTURE_PATH "texture" 42 | #define APP_BRUSH_PATH "brush" 43 | 44 | #endif 45 | -------------------------------------------------------------------------------- /configure.ac: -------------------------------------------------------------------------------- 1 | 2 | AC_PREREQ([2.69]) 3 | AC_INIT([azpainter], [2.1.0], [azelpg@gmail.com]) 4 | AM_INIT_AUTOMAKE([subdir-objects]) 5 | 6 | AC_CONFIG_SRCDIR([src/main.c]) 7 | AC_CONFIG_HEADERS([config.h]) 8 | 9 | AC_PROG_INSTALL 10 | AC_PROG_RANLIB 11 | 12 | # C compiler 13 | 14 | AC_PROG_CC 15 | AC_PROG_CC_STDC 16 | AC_C_BIGENDIAN([AC_DEFINE([MLIB_BIGENDIAN], [1], [BigEndian])]) 17 | 18 | # with 19 | 20 | AC_ARG_WITH([freetype-dir], 21 | AS_HELP_STRING([--with-freetype-dir], [set to freetype header directory]), 22 | [AC_SUBST([freetype_dir], [$withval])], 23 | [AC_SUBST([freetype_dir], [/usr/include/freetype2])] ) 24 | 25 | # need header 26 | 27 | AC_CHECK_HEADER([pthread.h], 28 | [AC_DEFINE([HAVE_PTHREAD_H], [1], [pthread.h])], 29 | AC_MSG_ERROR(pthread.h not found)) 30 | 31 | AC_CHECK_FILE("$freetype_dir/ft2build.h",,AC_MSG_ERROR([(freetype) ft2build.h not found])) 32 | AC_CHECK_HEADER([fontconfig/fontconfig.h],,AC_MSG_ERROR(fontconfig.h not found)) 33 | AC_CHECK_HEADER([zlib.h],,AC_MSG_ERROR(zlib.h not found)) 34 | AC_CHECK_HEADER([png.h],,AC_MSG_ERROR(png.h not found)) 35 | AC_CHECK_HEADER([jpeglib.h],,AC_MSG_ERROR(jpeglib.h not found)) 36 | 37 | # X11 ext 38 | 39 | AC_CHECK_LIB([Xext], [XShmCreateImage], [AC_DEFINE([HAVE_XEXT_XSHM], [1], [XShm])]) 40 | AC_CHECK_LIB([Xi], [XIQueryDevice], [have_xi2="yes"]) 41 | 42 | if test "$have_xi2" == "yes";then 43 | AC_DEFINE([HAVE_XEXT_XINPUT2], [1], [XInput2]) 44 | LIBS="$LIBS -lXi" 45 | fi 46 | 47 | # 48 | 49 | AC_PATH_X 50 | 51 | # 52 | 53 | AC_CONFIG_FILES([Makefile mlib/Makefile src/Makefile data/Makefile data/texture/Makefile desktop/Makefile]) 54 | AC_OUTPUT 55 | -------------------------------------------------------------------------------- /src/include/defMainWinCanvas.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************************** 21 | * メインウィンドウのキャンバスウィジェット 22 | ********************************************/ 23 | 24 | #ifndef DEF_MAINWINCANVAS_H 25 | #define DEF_MAINWINCANVAS_H 26 | 27 | #include "mScrollView.h" 28 | #include "mScrollViewArea.h" 29 | 30 | /** キャンバスメイン */ 31 | 32 | typedef struct _MainWinCanvas 33 | { 34 | mWidget wg; 35 | mScrollViewData sv; 36 | 37 | mPoint ptScrollBase; //スクロール基準位置 38 | }MainWinCanvas; 39 | 40 | /** キャンバス領域部分 */ 41 | 42 | typedef struct _MainWinCanvasArea 43 | { 44 | mWidget wg; 45 | mScrollViewAreaData sva; 46 | 47 | mCursor cursor_restore; 48 | mBox boxUpdate; 49 | mPoint ptTimerScrollDir, //スクロール方向と移動数 50 | ptTimerScrollSum; //総スクロール移動数 51 | 52 | mBool bPressSpace; //スペースキーが押されているか 53 | int press_rawkey; //現在押されているキー (キャンバスキー判定用) 54 | }MainWinCanvasArea; 55 | 56 | #endif 57 | -------------------------------------------------------------------------------- /src/other/ColorValue.c: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************************** 21 | * ColorValue 22 | *****************************************/ 23 | 24 | #include "mDef.h" 25 | 26 | #include "ColorValue.h" 27 | 28 | 29 | /** 0-100 の値を 0-0x8000 に変換 */ 30 | 31 | int Density100toFix15(int n) 32 | { 33 | return (int)(n / 100.0 * 0x8000 + 0.5); 34 | } 35 | 36 | 37 | /** RGBAFix15 -> RGB */ 38 | 39 | uint32_t RGBAFix15toRGB(RGBAFix15 *src) 40 | { 41 | int r,g,b; 42 | 43 | r = (src->r * 255 + 0x4000) >> 15; 44 | g = (src->g * 255 + 0x4000) >> 15; 45 | b = (src->b * 255 + 0x4000) >> 15; 46 | 47 | return (r << 16) | (g << 8) | b; 48 | } 49 | 50 | /** RGB 値 -> RGBFix15 */ 51 | 52 | void RGBtoRGBFix15(RGBFix15 *dst,uint32_t col) 53 | { 54 | dst->r = ((M_GET_R(col) << 15) + 127) / 255; 55 | dst->g = ((M_GET_G(col) << 15) + 127) / 255; 56 | dst->b = ((M_GET_B(col) << 15) + 127) / 255; 57 | } 58 | -------------------------------------------------------------------------------- /src/widget/DockCanvasView.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*********************************** 21 | * [dock] キャンバスビュー本体定義 22 | ***********************************/ 23 | 24 | #ifndef DOCK_CANVASVIEW_H 25 | #define DOCK_CANVASVIEW_H 26 | 27 | #include "DockObject.h" 28 | 29 | #define DOCKCANVASVIEW(p) ((DockCanvasView *)(p)) 30 | 31 | typedef struct _DockCanvasViewArea DockCanvasViewArea; 32 | 33 | typedef struct _DockCanvasView 34 | { 35 | DockObject obj; 36 | 37 | DockCanvasViewArea *area; 38 | mWidget *iconbtt; 39 | 40 | int zoom; 41 | double dscale,dscalediv, 42 | originX,originY; //原点位置 (イメージ座標) 43 | mPoint ptScroll, //スクロール位置 44 | ptLoupeCur; //ルーペ時の現在カーソル位置 (イメージ座標)。比較用 45 | }DockCanvasView; 46 | 47 | 48 | void DockCanvasView_adjustScroll(DockCanvasView *p); 49 | void DockCanvasView_setZoom_fit(DockCanvasView *p); 50 | mBool DockCanvasView_setZoom(DockCanvasView *p,int zoom); 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /src/include/defPixelMode.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * 塗りタイプ 22 | **********************************/ 23 | 24 | #ifndef DEF_PIXELMODE_H 25 | #define DEF_PIXELMODE_H 26 | 27 | enum 28 | { 29 | /* 通常ブラシ用 */ 30 | 31 | PIXELMODE_BLEND_PIXEL = 0, 32 | PIXELMODE_BLEND_STROKE, 33 | PIXELMODE_COMPARE_A, 34 | PIXELMODE_OVERWRITE_STYLE, 35 | PIXELMODE_OVERWRITE_SQUARE, 36 | PIXELMODE_DODGE, 37 | PIXELMODE_BURN, 38 | PIXELMODE_ADD, 39 | 40 | PIXELMODE_BRUSH_NUM, 41 | 42 | /* ドットペン時は消しゴムを追加 */ 43 | 44 | PIXELMODE_DOTPEN_ERASE = PIXELMODE_BRUSH_NUM, 45 | PIXELMODE_DOTPEN_NUM, 46 | 47 | /* 消しゴム用 */ 48 | 49 | PIXELMODE_ERASE_PIXEL = 0, 50 | PIXELMODE_ERASE_STROKE, 51 | 52 | PIXELMODE_ERASE_NUM, 53 | 54 | /* ツール用 */ 55 | 56 | PIXELMODE_TOOL_BLEND = 0, 57 | PIXELMODE_TOOL_COMPARE_A, 58 | PIXELMODE_TOOL_OVERWRITE, 59 | PIXELMODE_TOOL_ERASE 60 | }; 61 | 62 | #endif 63 | -------------------------------------------------------------------------------- /src/widget/CanvasCtrlBar.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************************* 21 | * DockCanvasCtl の操作バー 22 | *********************************************/ 23 | 24 | #ifndef CANVASCTRLBAR_H 25 | #define CANVASCTRLBAR_H 26 | 27 | typedef struct _CanvasCtrlBar CanvasCtrlBar; 28 | 29 | #define CANVASCTRLBAR_TYPE_ZOOM 0 30 | #define CANVASCTRLBAR_TYPE_ANGLE 1 31 | 32 | enum 33 | { 34 | CANVASCTRLBAR_BTT_SUB, 35 | CANVASCTRLBAR_BTT_ADD, 36 | CANVASCTRLBAR_BTT_RESET 37 | }; 38 | 39 | /* 通知タイプ */ 40 | 41 | enum 42 | { 43 | CANVASCTRLBAR_N_BAR, 44 | CANVASCTRLBAR_N_BUTTON 45 | }; 46 | 47 | /* 通知の param1 */ 48 | 49 | enum 50 | { 51 | CANVASCTRLBAR_N_BAR_TYPE_PRESS, 52 | CANVASCTRLBAR_N_BAR_TYPE_RELEASE, 53 | CANVASCTRLBAR_N_BAR_TYPE_MOTION 54 | }; 55 | 56 | CanvasCtrlBar *CanvasCtrlBar_new(mWidget *parent,int type); 57 | void CanvasCtrlBar_setPos(CanvasCtrlBar *p,int pos); 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /src/include/DrawPointBuf.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 自由線描画時のポイントデータ処理 22 | ************************************/ 23 | 24 | #ifndef DRAWPOINTBUF_H 25 | #define DRAWPOINTBUF_H 26 | 27 | typedef struct 28 | { 29 | double x,y,pressure; 30 | }DrawPointBuf_pt; 31 | 32 | //手ブレ補正タイプ 33 | enum 34 | { 35 | DRAWPOINTBUF_TYPE_NONE, 36 | DRAWPOINTBUF_TYPE_GAUSS, 37 | DRAWPOINTBUF_TYPE_LINEAR, 38 | DRAWPOINTBUF_TYPE_AVERAGE 39 | }; 40 | 41 | 42 | void DrawPointBuf_setFirstPoint(double x,double y,double pressure); 43 | void DrawPointBuf_addPoint(double x,double y,double pressure); 44 | 45 | void DrawPointBuf_setSmoothing(int type,int strength); 46 | 47 | mBool DrawPointBuf_getPoint(DrawPointBuf_pt *dst); 48 | mBool DrawPointBuf_getFinishPoint(DrawPointBuf_pt *dst); 49 | 50 | mBool DrawPointBuf_getPoint_int(mPoint *dst); 51 | mBool DrawPointBuf_getFinishPoint_int(mPoint *dst); 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /src/include/ColorValue.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /****************************** 21 | * カラー関連 22 | ******************************/ 23 | 24 | #ifndef COLORVALUE_H 25 | #define COLORVALUE_H 26 | 27 | #define RGBCONV_8_TO_FIX15(c) ((((c) << 15) + 127) / 255) 28 | #define RGBCONV_FIX15_TO_8(c) (((c) * 255 + 0x4000) >> 15) 29 | 30 | typedef union _RGB8 31 | { 32 | struct{ uint8_t r,g,b; }; 33 | uint8_t c[3]; 34 | }RGB8; 35 | 36 | typedef union _RGBAFix15 37 | { 38 | struct{ uint16_t r,g,b,a; }; 39 | uint16_t c[4]; 40 | uint64_t v64; 41 | }RGBAFix15; 42 | 43 | typedef union _RGBFix15 44 | { 45 | struct{ uint16_t r,g,b; }; 46 | uint16_t c[3]; 47 | }RGBFix15; 48 | 49 | typedef union _RGBADouble 50 | { 51 | struct{ double r,g,b,a; }; 52 | double ar[4]; 53 | }RGBADouble; 54 | 55 | 56 | int Density100toFix15(int n); 57 | 58 | uint32_t RGBAFix15toRGB(RGBAFix15 *src); 59 | void RGBtoRGBFix15(RGBFix15 *dst,uint32_t col); 60 | 61 | #endif 62 | -------------------------------------------------------------------------------- /src/include/dataImagePattern.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * イメージパターンデータ 22 | * 23 | * (main.c でグローバル定義されている) 24 | ***************************************/ 25 | 26 | 27 | #define IMGPAT_NUMBER_5x9_PATW (14 * 5) 28 | 29 | #ifdef IMAGEPATTERN_DEFINE 30 | 31 | /* 数値 '-' '.' '%' 度 (5x9) */ 32 | 33 | const unsigned char g_imgpat_number_5x9[81]={ 34 | 0x86,0x18,0x43,0x9e,0x79,0xc6,0x00,0x20,0x05, 35 | 0xc9,0xa4,0x24,0x42,0x4a,0x29,0x01,0x50,0x0b, 36 | 0xa9,0xa4,0x24,0x42,0x48,0x29,0x01,0xa0,0x0a, 37 | 0x89,0x20,0x54,0xce,0x49,0x29,0x01,0x80,0x04, 38 | 0x89,0x10,0x53,0x52,0x22,0xc6,0x3d,0x40,0x00, 39 | 0x89,0x08,0xf4,0x50,0x22,0x09,0x01,0x20,0x00, 40 | 0x89,0x84,0x44,0x50,0x22,0x89,0x00,0xa0,0x00, 41 | 0x89,0x84,0x44,0x52,0x22,0x89,0x00,0x53,0x01, 42 | 0x86,0x3c,0x43,0x8c,0x21,0x46,0x00,0x93,0x00 43 | }; 44 | 45 | #else 46 | 47 | extern const unsigned char g_imgpat_number_5x9[81]; 48 | 49 | #endif 50 | -------------------------------------------------------------------------------- /src/include/LayerDialogs.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************** 21 | * レイヤ関連ダイアログ 22 | *****************************/ 23 | 24 | #ifndef LAYER_DIALOGS_H 25 | #define LAYER_DIALOGS_H 26 | 27 | typedef struct 28 | { 29 | mStr strname; 30 | int coltype, 31 | blendmode; 32 | uint32_t col; 33 | }LayerNewDlgInfo; 34 | 35 | #define LAYERCOMBINEDLG_GET_TARGET(n) (n & 3) 36 | #define LAYERCOMBINEDLG_IS_NEWLAYER(n) ((n & (1<<2)) != 0) 37 | #define LAYERCOMBINEDLG_GET_COLTYPE(n) ((n >> 3) & 3) 38 | 39 | 40 | mBool LayerNewDlg_run(mWindow *owner,LayerNewDlgInfo *info); 41 | mBool LayerColorDlg_run(mWindow *owner,uint32_t *col); 42 | mBool LayerOptionDlg_run(mWindow *owner,mStr *strname,int *blendmode,uint32_t *col); 43 | int LayerTypeDlg_run(mWindow *owner,int curtype); 44 | int LayerCombineDlg_run(mWindow *owner,mBool cur_folder,mBool have_checked); 45 | 46 | mBool LayerColorDlg_run(mWindow *owner,uint32_t *col); 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /src/include/defMainWindow.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * MainWindow ウィジェット定義 22 | **********************************/ 23 | 24 | #ifndef DEF_MAINWINDOW_H 25 | #define DEF_MAINWINDOW_H 26 | 27 | #include "mWindowDef.h" 28 | #include "mStrDef.h" 29 | 30 | typedef struct _MainWindow 31 | { 32 | mWidget wg; 33 | mContainerData ct; 34 | mWindowData win; 35 | 36 | mWidget *ct_main, 37 | *splitter[3], //ペイン用スプリッター 38 | *toolbar; 39 | 40 | mMenu *menu_main, 41 | *menu_recentfile; 42 | 43 | mStr strFilename; //現在の編集ファイル名 (空で新規作成) 44 | uint32_t fileformat; //現在のファイルのフォーマットフラグ 45 | mBool saved; //一度でも保存されたか (FALSE で、新規か読み込んだ後保存されていない) 46 | }MainWindow; 47 | 48 | #define MAINWINDOW(p) ((MainWindow *)(p)) 49 | #define MAINWINDOW_CMDID_RECENTFILE 0x10000 50 | 51 | #define MAINWINDOW_CMDID_ZOOM_TOP 10000 52 | /* +2000 までが範囲。 53 | * ショートカットキーのコマンドとしても使うので、0xffff までの範囲にしなければいけない。 */ 54 | 55 | #endif 56 | -------------------------------------------------------------------------------- /src/include/FillPolygon.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 多角形塗りつぶし処理 22 | ************************************/ 23 | 24 | #ifndef FILLPOLYGON_H 25 | #define FILLPOLYGON_H 26 | 27 | typedef struct _FillPolygon FillPolygon; 28 | 29 | FillPolygon *FillPolygon_new(); 30 | void FillPolygon_free(FillPolygon *p); 31 | 32 | mBool FillPolygon_addPoint(FillPolygon *p,double x,double y); 33 | mBool FillPolygon_closePoint(FillPolygon *p); 34 | 35 | mBool FillPolygon_beginDraw(FillPolygon *p,mBool bAntiAlias); 36 | void FillPolygon_getMinMaxY(FillPolygon *p,int *ymin,int *ymax); 37 | void FillPolygon_getDrawRect(FillPolygon *p,mRect *rc); 38 | 39 | mBool FillPolygon_getIntersection_noAA(FillPolygon *p,int y); 40 | mBool FillPolygon_getNextLine_noAA(FillPolygon *p,int *x1,int *x2); 41 | 42 | mBool FillPolygon_setXBuf_AA(FillPolygon *p,int y); 43 | uint16_t *FillPolygon_getAABuf(FillPolygon *p,int *xmin,int *width); 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /src/include/defFileFormat.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 画像ファイルフォーマット定義 22 | ************************************/ 23 | 24 | #ifndef DEF_FILEFORMAT_H 25 | #define DEF_FILEFORMAT_H 26 | 27 | enum 28 | { 29 | FILEFORMAT_UNKNOWN = 0, 30 | 31 | FILEFORMAT_PNG = 1<<0, 32 | FILEFORMAT_JPEG = 1<<1, 33 | FILEFORMAT_GIF = 1<<2, 34 | FILEFORMAT_BMP = 1<<3, 35 | 36 | FILEFORMAT_APD = 1<<4, 37 | FILEFORMAT_ADW = 1<<5, 38 | FILEFORMAT_PSD = 1<<6, 39 | 40 | /* option */ 41 | 42 | FILEFORMAT_APD_v1v2 = 1<<16, 43 | FILEFORMAT_APD_v3 = 1<<17, 44 | 45 | FILEFORMAT_ALPHA_CHANNEL = 1<<18, //アルファチャンネル (保存時) 46 | 47 | // 48 | 49 | FILEFORMAT_NORMAL_IMAGE = FILEFORMAT_PNG | FILEFORMAT_JPEG | FILEFORMAT_GIF | FILEFORMAT_BMP, 50 | FILEFORMAT_OPEN_LAYERIMAGE = FILEFORMAT_NORMAL_IMAGE | FILEFORMAT_APD_v3 51 | }; 52 | 53 | /* MainWindow_file.c */ 54 | uint32_t FileFormat_getbyFileHeader(const char *filename); 55 | 56 | #endif 57 | -------------------------------------------------------------------------------- /src/include/trid_layer_dialogs.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * 翻訳文字列ID : レイヤ関連ダイアログ 22 | ***************************************/ 23 | 24 | #ifndef TRID_LAYER_DIALOGS_H 25 | #define TRID_LAYER_DIALOGS_H 26 | 27 | enum 28 | { 29 | //各タイトル 30 | TRID_LAYERDLGS_TITLE_NEW, 31 | TRID_LAYERDLGS_TITLE_COLOR, 32 | TRID_LAYERDLGS_TITLE_OPTION, 33 | TRID_LAYERDLGS_TITLE_SETTYPE, 34 | TRID_LAYERDLGS_TITLE_COMBINE, 35 | 36 | //各項目 37 | TRID_LAYERDLGS_TYPE = 100, 38 | TRID_LAYERDLGS_BLENDMODE, 39 | TRID_LAYERDLGS_COLOR, 40 | TRID_LAYERDLGS_PALETTE_HELP, 41 | TRID_LAYERDLGS_LAYERCOLOR_TIPS, 42 | TRID_LAYERDLGS_LUM_TO_ALPHA, 43 | TRID_LAYERDLGS_COMBINE_NEWLAYER, 44 | TRID_LAYERDLGS_COMBINE_DSTTYPE, 45 | TRID_LAYERDLGS_COMBINE_HELP, 46 | TRID_LAYERDLGS_EDITNAMELIST_MENU, 47 | TRID_LAYERDLGS_EDITNAMELIST_TITLE, 48 | TRID_LAYERDLGS_EDITNAMELIST_MES, 49 | 50 | TRID_LAYERDLGS_COMBINE_TYPE_TOP = 200 51 | }; 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /src/include/defCanvasKeyID.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * キャンバスキーコマンドID 22 | ***************************************/ 23 | 24 | #ifndef DEF_CANVASKEY_ID_H 25 | #define DEF_CANVASKEY_ID_H 26 | 27 | enum 28 | { 29 | CANVASKEYID_CMD_TOOL = 1, //ツール変更 30 | CANVASKEYID_CMD_DRAWTYPE = 30, //描画タイプ変更 31 | CANVASKEYID_CMD_OTHER = 60, //他コマンド 32 | CANVASKEYID_OP_TOOL = 100, //+キー:ツール動作 33 | CANVASKEYID_OP_BRUSHDRAW = 130, //+キー:ブラシ描画 34 | CANVASKEYID_OP_SELECT = 150, //+キー:選択範囲ツール 35 | CANVASKEYID_OP_OTHER = 160, //+キー:他 36 | 37 | CANVASKEY_CMD_OTHER_NUM = 12, //他コマンドの数 38 | CANVASKEY_OP_OTHER_NUM = 9 //+キー:他の数 39 | }; 40 | 41 | //+キー操作のコマンドか 42 | #define CANVASKEY_IS_PLUS_MOTION(id) ((id) >= CANVASKEYID_OP_TOOL && (id) < CANVASKEYID_OP_OTHER + CANVASKEY_OP_OTHER_NUM) 43 | 44 | #define CANVASKEYID_CMD_OTHER_ZOOM_UP (CANVASKEYID_CMD_OTHER + 4) 45 | #define CANVASKEYID_CMD_OTHER_ZOOM_DOWN (CANVASKEYID_CMD_OTHER + 5) 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /src/widget/DockImageViewer.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************* 21 | * [dock] イメージビューア本体定義 22 | *************************************/ 23 | 24 | #ifndef DOCK_IMAGEVIEWER_H 25 | #define DOCK_IMAGEVIEWER_H 26 | 27 | #include "mStrDef.h" 28 | #include "DockObject.h" 29 | 30 | #define DOCKIMAGEVIEWER(p) ((DockImageViewer *)(p)) 31 | 32 | typedef struct _DockImageViewerArea DockImageViewerArea; 33 | 34 | typedef struct _DockImageViewer 35 | { 36 | DockObject obj; 37 | 38 | DockImageViewerArea *area; 39 | mWidget *iconbtt; 40 | 41 | ImageBuf24 *img; 42 | int scrx,scry, 43 | zoom; 44 | double dscale,dscalediv; 45 | 46 | mStr strFileName; 47 | }DockImageViewer; 48 | 49 | 50 | void DockImageViewer_adjustScroll(DockImageViewer *p); 51 | void DockImageViewer_setZoom_fit(DockImageViewer *p); 52 | mBool DockImageViewer_setZoom(DockImageViewer *p,int zoom); 53 | void DockImageViewer_loadImage(DockImageViewer *p,const char *filename); 54 | 55 | #endif 56 | -------------------------------------------------------------------------------- /src/include/ImageBuf8.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 8bit イメージ 22 | ************************************/ 23 | 24 | #ifndef IMAGEBUF8_H 25 | #define IMAGEBUF8_H 26 | 27 | typedef struct _ImageBuf24 ImageBuf24; 28 | 29 | typedef struct _ImageBuf8 30 | { 31 | uint8_t *buf; 32 | uint32_t bufsize; 33 | int w,h; 34 | }ImageBuf8; 35 | 36 | #define IMAGEBUF8_GETBUFPT(p,x,y) ((p)->buf + (y) * (p)->w + (x)) 37 | 38 | 39 | void ImageBuf8_free(ImageBuf8 *p); 40 | ImageBuf8 *ImageBuf8_new(int w,int h); 41 | 42 | void ImageBuf8_clear(ImageBuf8 *p); 43 | uint8_t ImageBuf8_getPixel_forTexture(ImageBuf8 *p,int x,int y); 44 | 45 | ImageBuf8 *ImageBuf8_createFromImageBuf24(ImageBuf24 *src); 46 | ImageBuf8 *ImageBuf8_createFromImageBuf24_forBrush(ImageBuf24 *src); 47 | 48 | void ImageBuf8_drawTexturePreview(ImageBuf8 *p,mPixbuf *pixbuf,int x,int y,int w,int h); 49 | void ImageBuf8_drawBrushPreview(ImageBuf8 *p,mPixbuf *pixbuf,int x,int y,int w,int h); 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /src/include/draw_file.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /********************************** 21 | * DrawData ファイル読み書き 22 | **********************************/ 23 | 24 | #ifndef DRAW_FILE_H 25 | #define DRAW_FILE_H 26 | 27 | typedef struct _mPopupProgress mPopupProgress; 28 | 29 | mBool drawFile_save_image(DrawData *p,const char *filename,int format,mPopupProgress *prog); 30 | 31 | int drawFile_load_adw(const char *filename,mPopupProgress *prog); 32 | int drawFile_load_apd_v1v2(const char *filename,mPopupProgress *prog); 33 | 34 | mBool drawFile_load_apd_v3(DrawData *p,const char *filename,mPopupProgress *prog); 35 | mBool drawFile_save_apd_v3(DrawData *p,const char *filename,mPopupProgress *prog); 36 | 37 | mBool drawFile_load_psd(DrawData *p,const char *filename,mPopupProgress *prog,char **errmes); 38 | mBool drawFile_save_psd_layer(DrawData *p,const char *filename,mPopupProgress *prog); 39 | mBool drawFile_save_psd_image(DrawData *p,int type,const char *filename,mPopupProgress *prog); 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /src/include/ImageBuf24.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * 8bit R-G-B イメージ 22 | ************************************/ 23 | 24 | #ifndef IMAGEBUF24_H 25 | #define IMAGEBUF24_H 26 | 27 | 28 | typedef struct _ImageBuf24 29 | { 30 | uint8_t *buf; 31 | int w,h,pitch; 32 | }ImageBuf24; 33 | 34 | /** キャンバス描画用データ */ 35 | 36 | typedef struct 37 | { 38 | int scrollx,scrolly, 39 | mirror; 40 | double originx,originy, 41 | scalediv; 42 | uint32_t bkgndcol; 43 | }ImageBuf24CanvasInfo; 44 | 45 | 46 | ImageBuf24 *ImageBuf24_new(int w,int h); 47 | void ImageBuf24_free(ImageBuf24 *p); 48 | 49 | uint8_t *ImageBuf24_getPixelBuf(ImageBuf24 *p,int x,int y); 50 | 51 | ImageBuf24 *ImageBuf24_loadFile(const char *filename); 52 | 53 | void ImageBuf24_drawCanvas_nearest(ImageBuf24 *src,mPixbuf *dst, 54 | mBox *boxdst,ImageBuf24CanvasInfo *info); 55 | void ImageBuf24_drawCanvas_oversamp(ImageBuf24 *src,mPixbuf *dst, 56 | mBox *boxdst,ImageBuf24CanvasInfo *info); 57 | 58 | #endif 59 | -------------------------------------------------------------------------------- /src/include/AppCursor.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************** 21 | * アプリケーション用カーソル 22 | ********************************/ 23 | 24 | #ifndef APP_CURSOR_H 25 | #define APP_CURSOR_H 26 | 27 | enum APP_CURSOR 28 | { 29 | APP_CURSOR_DRAW, //fix 30 | APP_CURSOR_WAIT, //fix 31 | 32 | APP_CURSOR_HAND, 33 | APP_CURSOR_HAND_DRAG, 34 | APP_CURSOR_ROTATE, 35 | APP_CURSOR_ITEM_MOVE, 36 | APP_CURSOR_MOVE, 37 | APP_CURSOR_SPOIT, 38 | APP_CURSOR_SELECT, 39 | APP_CURSOR_SEL_MOVE, 40 | APP_CURSOR_STAMP, 41 | APP_CURSOR_TEXT, 42 | APP_CURSOR_ZOOM_DRAG, 43 | 44 | APP_CURSOR_LEFT_TOP, 45 | APP_CURSOR_RIGHT_TOP, 46 | APP_CURSOR_RESIZE_HORZ, 47 | APP_CURSOR_RESIZE_VERT 48 | }; 49 | 50 | void AppCursor_init(uint8_t *drawcursor); 51 | void AppCursor_free(); 52 | 53 | void AppCursor_setDrawCursor(uint8_t *buf); 54 | 55 | mCursor AppCursor_getWaitCursor(); 56 | mCursor AppCursor_getForCanvas(int no); 57 | mCursor AppCursor_getForDrag(int no); 58 | mCursor AppCursor_getForDialog(int no); 59 | 60 | #endif 61 | -------------------------------------------------------------------------------- /src/other/UndoMaster.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************** 21 | * アンドゥ管理データ 22 | ********************************/ 23 | 24 | typedef struct _mZlibEncode mZlibEncode; 25 | typedef struct _mZlibDecode mZlibDecode; 26 | 27 | typedef struct 28 | { 29 | mUndo undo; 30 | 31 | UndoUpdateInfo update; //(作業用) 更新情報 32 | uint8_t change; //データが変更されたかのフラグに使う 33 | 34 | uint32_t used_bufsize; //現在使われているアンドゥバッファの総サイズ 35 | int cur_fileno, //ファイル番号の現在値 36 | write_type, //書き込み時の出力タイプ 37 | write_tmpsize, //一時バッファに書き込まれたサイズ 38 | write_remain; //可変書き込み時の残りサイズ 39 | uint8_t *writetmpbuf, //書き込み時の一時出力バッファ 40 | *workbuf1, //タイルイメージ用バッファ 41 | *workbuf2, 42 | *workbuf_flags, 43 | *write_dst, //書き込み位置 44 | *read_dst; //読み込み位置 45 | FILE *writefp, 46 | *readfp; 47 | fpos_t writefpos; //[file] 書き込み位置記録 48 | 49 | mZlibEncode *zenc; //[file] レイヤタイル圧縮用 50 | mZlibDecode *zdec; //[file] レイヤタイル展開用 51 | }UndoMaster; 52 | 53 | extern UndoMaster *g_app_undo; 54 | 55 | #define UNDO_WRITETEMPBUFSIZE (128 * 1024) 56 | -------------------------------------------------------------------------------- /mlib/include/mConfig.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_CONFIG_H 33 | #define MLIB_CONFIG_H 34 | 35 | #ifdef HAVE_CONFIG_H 36 | #include "config.h" 37 | #endif 38 | 39 | #define MLIB_ENABLE_PENTABLET 1 40 | 41 | #endif 42 | -------------------------------------------------------------------------------- /mlib/include/mStrDef.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_STRDEF_H 33 | #define MLIB_STRDEF_H 34 | 35 | struct _mStr 36 | { 37 | char *buf; 38 | int len,allocsize; 39 | }; 40 | 41 | #define MSTR_INIT {0,0,0} 42 | 43 | #endif 44 | -------------------------------------------------------------------------------- /src/include/defCanvasInfo.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /*************************************** 21 | * キャンバスのパラメータ情報 22 | ***************************************/ 23 | 24 | #ifndef DEF_CANVASINFO_H 25 | #define DEF_CANVASINFO_H 26 | 27 | /** 表示倍率/回転の計算時のパラメータ */ 28 | 29 | typedef struct _CanvasViewParam 30 | { 31 | double scale,scalediv, //倍率 32 | rd, //角度 33 | cos,sin, //cos,sin 値 34 | cosrev,sinrev; //cos,sin 逆回転値 35 | }CanvasViewParam; 36 | 37 | /** キャンバス描画用のパラメータ */ 38 | 39 | typedef struct _CanvasDrawInfo 40 | { 41 | mBox boxdst; //描画先範囲 42 | double originx,originy; //イメージの原点位置 43 | int scrollx,scrolly, //スクロール位置 44 | mirror, //左右反転表示か 45 | imgw,imgh; 46 | uint32_t bkgndcol; //イメージ範囲外の色 47 | CanvasViewParam *param; //計算用パラメータ 48 | }CanvasDrawInfo; 49 | 50 | /* draw_calc.c */ 51 | 52 | void CanvasDrawInfo_imageToarea(CanvasDrawInfo *p,double x,double y,double *px,double *py); 53 | void CanvasDrawInfo_imageToarea_pt(CanvasDrawInfo *p,double x,double y,mPoint *pt); 54 | void CanvasDrawInfo_getImageIncParam(CanvasDrawInfo *p,double *dst); 55 | 56 | #endif 57 | -------------------------------------------------------------------------------- /translation/HOWTO_ja: -------------------------------------------------------------------------------- 1 | ======================================= 2 | 翻訳方法 3 | ======================================= 4 | 5 | ここでは、例として英語用の翻訳ファイルを作成する手順を説明します。 6 | 7 | 8 | <1> 翻訳元のテキストファイルを、翻訳したい言語用にコピー 9 | -------------------------------------------------------- 10 | 11 | $ cp ja en_US 12 | 13 | - ファイル名は、2文字または5文字の言語名にしてください。 14 | 15 | - システムの言語名が5文字の名前と一致する場合はそのファイルが優先的に読み込まれ、 16 | 5文字の名前と一致するものがない場合、先頭2文字の名前と一致するものがあれば 17 | それが読み込まれます。 18 | 19 | - システムの言語が en_US だった場合、最初に en_US.mtr を探し、 20 | 見つからなければ、en.mtr を探します。 21 | それもなかった場合は、ソフトに埋め込まれたデフォルトの文字列 (英語) が使われます。 22 | 23 | 24 | <2> コピーしたテキストファイルを編集 25 | --------------------------------------- 26 | 27 | [例] 28 | ja: 3=はい 29 | en_US: 3=Yes 30 | 31 | 32 | <3> テキストからバイナリデータに変換するツールをコンパイル 33 | --------------------------------------------------------- 34 | 35 | mtrconv.c をコンパイルして、実行ファイルを生成します。 36 | 37 | mtrconv.c のあるディレクトリで以下のコマンドを実行すると、 38 | Makefile を使うことで簡単に作成できます。 39 | 40 | $ make 41 | 42 | 43 | <4> ツールを使って、バイナリデータを生成 44 | ------------------------------------------ 45 | 46 | $ ./mtrconv en_US en_US.mtr 47 | 48 | 第一引数に変換元のテキストファイル名を、 49 | 第二引数に出力するバイナリデータのファイル名を指定します。 50 | 51 | 52 | <5> 確認 53 | ----------------------- 54 | 55 | 実際に実行して、翻訳できているか確認します。 56 | 57 | $ azpainter --trfile en_US.mtr 58 | 59 | --trfile オプションを使うと、翻訳ファイルを直接指定して 60 | 読み込ませることができます。 61 | 62 | 63 | 64 | <6> *.mtr ファイルを、 65 | AzPainter のインストール先のディレクトリにコピー 66 | ------------------------------------------------------- 67 | 68 | システムの言語から自動で最適な翻訳ファイルを読み込ませたい場合は、 69 | mtr ファイルを AzPainter のデータ用ディレクトリに置く必要があります。 70 | 71 | 翻訳ファイルを置くディレクトリの場所は、 72 | ソースファイルからコンパイルした場合、 73 | デフォルトで '/usr/local/share/azpainter/tr' です。 74 | 別の場所にインストールした場合は、その場所にコピーしてくさだい。 75 | 76 | # cp en_US.mtr /usr/local/share/azpainter/tr 77 | 78 | これで、起動時にはデフォルトでシステムの言語のファイルが開かれるので、 79 | システムが en_US なら en_US.mtr が読み込まれます。 80 | -------------------------------------------------------------------------------- /mlib/include/mUtilSys.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_UTIL_SYS_H 33 | #define MLIB_UTIL_SYS_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | mBool mExec(const char *cmd); 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /mlib/include/mEnumFont.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_ENUMFONT_H 33 | #define MLIB_ENUMFONT_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | char **mEnumFontFamily(); 40 | char **mEnumFontStyle(const char *family); 41 | 42 | #ifdef __cplusplus 43 | } 44 | #endif 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /src/include/defTool.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************************** 21 | * ツールの列挙値定義 22 | ********************************************/ 23 | 24 | #ifndef DEF_TOOL_H 25 | #define DEF_TOOL_H 26 | 27 | /* ツール番号 */ 28 | 29 | enum TOOLNO 30 | { 31 | TOOL_BRUSH, 32 | TOOL_FILL_POLYGON, 33 | TOOL_FILL_POLYGON_ERASE, 34 | TOOL_FILL, 35 | TOOL_FILL_ERASE, 36 | TOOL_GRADATION, 37 | TOOL_TEXT, 38 | TOOL_MOVE, 39 | TOOL_MAGICWAND, 40 | TOOL_SELECT, 41 | TOOL_BOXEDIT, 42 | TOOL_STAMP, 43 | TOOL_CANVAS_MOVE, 44 | TOOL_CANVAS_ROTATE, 45 | TOOL_SPOIT, 46 | 47 | TOOL_NUM 48 | }; 49 | 50 | /* 描画タイプ */ 51 | 52 | enum TOOLSUBNO 53 | { 54 | TOOLSUB_DRAW_FREE, 55 | TOOLSUB_DRAW_LINE, 56 | TOOLSUB_DRAW_BOX, 57 | TOOLSUB_DRAW_ELLIPSE, 58 | TOOLSUB_DRAW_SUCCLINE, 59 | TOOLSUB_DRAW_CONCLINE, 60 | TOOLSUB_DRAW_BEZIER, 61 | TOOLSUB_DRAW_SPLINE, 62 | 63 | TOOLSUB_DRAW_NUM 64 | }; 65 | 66 | /* 選択範囲サブ */ 67 | 68 | enum 69 | { 70 | TOOLSUB_SEL_BOX, 71 | TOOLSUB_SEL_POLYGON, 72 | TOOLSUB_SEL_LASSO, 73 | TOOLSUB_SEL_IMGMOVE, 74 | TOOLSUB_SEL_IMGCOPY, 75 | TOOLSUB_SEL_POSMOVE, 76 | 77 | TOOLSUB_SEL_NUM 78 | }; 79 | 80 | #endif 81 | -------------------------------------------------------------------------------- /mlib/include/mWidgetBuilder.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_WIDGETBUILDER_H 33 | #define MLIB_WIDGETBUILDER_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | mBool mWidgetBuilderCreateFromText(mWidget *parent,const char *text); 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /src/AppResource.c: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************************** 21 | * アプリリソース関連関数 22 | *****************************************/ 23 | 24 | #include "mDef.h" 25 | #include "mStr.h" 26 | #include "mImageList.h" 27 | 28 | //----------------- 29 | 30 | static const uint8_t g_toolbar_btts[] = { 31 | 0,1,15,254, 32 | 2,3,4,254, 33 | 5,6,7,8,9,254, 34 | 10,254, 35 | 11,12,254, 36 | 13,254, 37 | 14, 38 | 255 39 | }; 40 | 41 | //----------------- 42 | 43 | 44 | /** アイコン用のイメージリスト読み込み */ 45 | 46 | mImageList *AppResource_loadIconImage(const char *filename,int size) 47 | { 48 | mStr str = MSTR_INIT; 49 | mImageList *img; 50 | 51 | //指定サイズ読み込み 52 | 53 | mStrSetFormat(&str, "!/%dx%d/%s", size, size, filename); 54 | 55 | img = mImageListLoadPNG(str.buf, size, 0x00ff00); 56 | 57 | //失敗時は16x16 58 | 59 | if(!img) 60 | { 61 | mStrSetFormat(&str, "!/16x16/%s", filename); 62 | 63 | img = mImageListLoadPNG(str.buf, 16, 0x00ff00); 64 | } 65 | 66 | mStrFree(&str); 67 | 68 | return img; 69 | } 70 | 71 | /** ツールバーのボタンデータのデフォルト値取得 */ 72 | 73 | const uint8_t *AppResource_getToolbarBtt_default() 74 | { 75 | return g_toolbar_btts; 76 | } 77 | -------------------------------------------------------------------------------- /mlib/include/mFTGSUB.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_FTGSUB_H 33 | #define MLIB_FTGSUB_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void *mFTGSUB_getVertTable(void *gsub); 40 | uint32_t mFTGSUB_getVertGlyph(void *table,uint32_t glyph); 41 | 42 | #ifdef __cplusplus 43 | } 44 | #endif 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /mlib/include/mToolTip.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_TOOLTIP_H 33 | #define MLIB_TOOLTIP_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | typedef struct _mToolTip mToolTip; 40 | 41 | mToolTip *mToolTipShow(mToolTip *p,int rootx,int rooty,const char *text); 42 | 43 | #ifdef __cplusplus 44 | } 45 | #endif 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /mlib/src/x11/x11_dnd.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_X11_DND_H 33 | #define MLIB_X11_DND_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void mX11DND_free(mX11DND *p); 40 | mX11DND *mX11DND_alloc(); 41 | 42 | mBool mX11DND_onClientMessage(mX11DND *p,XClientMessageEvent *ev); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /mlib/include/mClipboard.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_CLIPBOARD_H 33 | #define MLIB_CLIPBOARD_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | char *mClipboardGetText(mWidget *wg); 40 | mBool mClipboardSetText(mWidget *wg,const char *text,int size); 41 | mBool mClipboardSave(mWidget *wg); 42 | 43 | #ifdef __cplusplus 44 | } 45 | #endif 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /src/widget/DockOption_sub.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /****************************************** 21 | * [Dock]オプションのウィジェット作成関数 22 | ******************************************/ 23 | 24 | #ifndef DOCK_OPTION_SUB_H 25 | #define DOCK_OPTION_SUB_H 26 | 27 | typedef struct _ValueBar ValueBar; 28 | typedef struct _mComboBox mComboBox; 29 | 30 | /* タブ内容作成 */ 31 | 32 | mWidget *DockOption_createTab_tool(mWidget *parent); 33 | mWidget *DockOption_createTab_tool_grad(mWidget *parent); 34 | 35 | mWidget *DockOption_createTab_texture(mWidget *parent); 36 | mWidget *DockOption_createTab_rule(mWidget *parent); 37 | mWidget *DockOption_createTab_headtail(mWidget *parent); 38 | 39 | /* ウィジェット作成 */ 40 | 41 | mWidget *DockOption_createMainContainer(int size,mWidget *parent, 42 | int (*event)(mWidget *,mEvent *)); 43 | 44 | ValueBar *DockOption_createDensityBar(mWidget *parent,int id,int val); 45 | ValueBar *DockOption_createBar(mWidget *parent,int wid,int label_id,int min,int max,int val); 46 | 47 | mComboBox *DockOption_createPixelModeCombo(mWidget *parent,int id,uint8_t *dat,int sel); 48 | mComboBox *DockOption_createComboBox(mWidget *parent,int cbid,int trid); 49 | 50 | /* ほか */ 51 | 52 | void DockOption_toolStamp_changeImage(mWidget *wg); 53 | 54 | #endif 55 | -------------------------------------------------------------------------------- /mlib/src/x11/x11_im.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_X11_IM_H 33 | #define MLIB_X11_IM_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void mX11IM_close(void); 40 | void mX11IM_init(void); 41 | 42 | void mX11IC_destroy(mWindow *win); 43 | void mX11IC_init(mWindow *win); 44 | void mX11IC_setFocus(mWindow *win,int focusin); 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif 51 | -------------------------------------------------------------------------------- /mlib/include/mRandXorShift.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_RAND_XORSHIFT_H 33 | #define MLIB_RAND_XORSHIFT_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void mRandXorShift_init(uint32_t seed); 40 | uint32_t mRandXorShift_getUint32(); 41 | int mRandXorShift_getIntRange(int min,int max); 42 | double mRandXorShift_getDouble(); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /mlib/include/mFileStat.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_FILESTAT_H 33 | #define MLIB_FILESTAT_H 34 | 35 | typedef struct _mFileStat 36 | { 37 | int perm; 38 | uint32_t flags; 39 | uint64_t size, 40 | timeAccess, 41 | timeModify; 42 | }mFileStat; 43 | 44 | enum MFILESTAT_FLAGS 45 | { 46 | MFILESTAT_F_NORMAL = 1<<0, 47 | MFILESTAT_F_DIRECTORY = 1<<1, 48 | MFILESTAT_F_SYMLINK = 1<<2 49 | }; 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /mlib/src/private/mListViewPopup.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_LISTVIEW_POPUP_H 33 | #define MLIB_LISTVIEW_POPUP_H 34 | 35 | enum 36 | { 37 | MLISTVIEWPOPUP_S_VERTSCR = 1<<0 38 | }; 39 | 40 | #ifdef __cplusplus 41 | extern "C" { 42 | #endif 43 | 44 | void mListViewPopupRun(mWidget *callwg,mLVItemMan *manager, 45 | uint32_t style,int x,int y,int w,int h,int itemh); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /mlib/include/mCursor.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_CURSOR_H 33 | #define MLIB_CURSOR_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | enum MCURSOR_DEF 40 | { 41 | MCURSOR_DEF_HSPLIT = 1, 42 | MCURSOR_DEF_VSPLIT 43 | }; 44 | 45 | void mCursorFree(mCursor cur); 46 | mCursor mCursorCreateMono(const uint8_t *buf); 47 | mCursor mCursorGetDefault(int type); 48 | 49 | #ifdef __cplusplus 50 | } 51 | #endif 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /mlib/include/mListDef.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_LISTDEF_H 33 | #define MLIB_LISTDEF_H 34 | 35 | typedef struct _mList mList; 36 | typedef struct _mListItem mListItem; 37 | 38 | struct _mListItem 39 | { 40 | mListItem *prev,*next; 41 | void (*destroy)(mListItem *); 42 | }; 43 | 44 | struct _mList 45 | { 46 | mListItem *top,*bottom; 47 | int num; 48 | }; 49 | 50 | #define MLIST_INIT {0,0,0} 51 | #define M_LISTITEM(p) ((mListItem *)(p)) 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /mlib/include/mTextRead.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_TEXTREAD_H 33 | #define MLIB_TEXTREAD_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | typedef struct _mTextRead mTextRead; 40 | 41 | void mTextReadEnd(mTextRead *p); 42 | mTextRead *mTextRead_readFile(const char *filename); 43 | 44 | char *mTextReadGetLine(mTextRead *p); 45 | char *mTextReadGetLine_skipEmpty(mTextRead *p); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /mlib/src/x11/x11_window.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_X11_WINDOW_H 33 | #define MLIB_X11_WINDOW_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void mX11WindowSetEventMask(mWindow *p,long mask,mBool append); 40 | void mX11WindowSetWindowType(mWindow *p,const char *name); 41 | void mX11WindowSetUserTime(mWindow *p,unsigned long time); 42 | void mX11WindowSetDecoration(mWindow *p); 43 | 44 | #ifdef __cplusplus 45 | } 46 | #endif 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /src/include/FilterDrawInfo.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * フィルタ描画情報 22 | ************************************/ 23 | 24 | #ifndef FILTERDRAWINFO_H 25 | #define FILTERDRAWINFO_H 26 | 27 | #include "ColorValue.h" 28 | 29 | typedef struct _FilterDrawInfo FilterDrawInfo; 30 | typedef struct _mPopupProgress mPopupProgress; 31 | typedef struct _TileImage TileImage; 32 | 33 | typedef mBool (*FilterDrawFunc)(FilterDrawInfo *); 34 | 35 | 36 | #define FILTER_BAR_NUM 8 //最大8=漫画用集中線など 37 | #define FILTER_CHECKBTT_NUM 3 //最大3=ハーフトーン 38 | #define FILTER_COMBOBOX_NUM 3 //最大3=縁に沿って点描画 39 | 40 | 41 | struct _FilterDrawInfo 42 | { 43 | TileImage *imgsrc, 44 | *imgdst, 45 | *imgref, //参照イメージ先頭 46 | *imgsel; //選択範囲 (カラー処理のプレビュー用) 47 | mPopupProgress *prog; 48 | 49 | mRect rc; //イメージを処理する範囲 (イメージ座標) 50 | mBox box; 51 | 52 | FilterDrawFunc drawfunc; 53 | 54 | RGBAFix15 rgba15Draw, //描画色 55 | rgba15Bkgnd; //背景色 56 | 57 | int imgx,imgy, //イメージ位置 (キャンバス上クリック位置) 58 | val_bar[FILTER_BAR_NUM]; 59 | uint8_t val_ckbtt[FILTER_CHECKBTT_NUM], 60 | val_combo[FILTER_COMBOBOX_NUM]; 61 | 62 | mBool in_dialog, //ダイアログ中は TRUE、実際の描画時は FALSE 63 | clipping; //イメージ範囲外をクリッピングするか 64 | 65 | /* フィルタ処理中の作業用 */ 66 | 67 | int ntmp[4]; //最大4=RGBずらし 68 | void *ptmp[1]; //テーブルバッファ用 69 | }; 70 | 71 | #endif 72 | -------------------------------------------------------------------------------- /mlib/include/mTreeDef.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_TREE_DEF_H 33 | #define MLIB_TREE_DEF_H 34 | 35 | typedef struct _mTreeItem mTreeItem; 36 | 37 | struct _mTreeItem 38 | { 39 | mTreeItem *prev,*next,*first,*last,*parent; 40 | void (*destroy)(mTreeItem *); 41 | }; 42 | 43 | typedef struct _mTree 44 | { 45 | mTreeItem *top,*bottom; 46 | }mTree; 47 | 48 | 49 | #define M_TREE(p) ((mTree *)(p)) 50 | #define M_TREEITEM(p) ((mTreeItem *)(p)) 51 | #define MTREE_INIT {0,0} 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /src/include/TileImageDrawInfo.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /***************************************************** 21 | * TileImage へ描画する際の情報 22 | * 23 | * (g_tileimage_dinfo としてグローバル定義されている) 24 | *****************************************************/ 25 | 26 | #ifndef TILEIMAGE_DRAWINFO_H 27 | #define TILEIMAGE_DRAWINFO_H 28 | 29 | typedef struct _BrushDrawParam BrushDrawParam; 30 | typedef struct _ImageBuf8 ImageBuf8; 31 | 32 | 33 | typedef struct _TileImageDrawInfo 34 | { 35 | int imgw,imgh, //イメージの幅、高さ 36 | err; //エラー 37 | 38 | RGBFix15 *colmask_col; //色マスクの色 (r=0xffff で終端) 39 | 40 | uint8_t colmask_type, //色マスクタイプ 41 | alphamask_type; //アルファマスクタイプ 42 | 43 | mRect rcdraw; //描画された範囲 44 | 45 | TileImageInfo tileimginfo; //アンドゥ用、描画開始時のタイル情報 46 | 47 | TileImage *img_save, //描画前の保存用 48 | *img_brush_stroke, //ブラシストローク濃度用 49 | *img_mask, //マスクイメージ (NULL でなし) 50 | *img_sel; //選択範囲 51 | ImageBuf8 *texture; //テクスチャイメージ (NULL でなし) 52 | 53 | BrushDrawParam *brushparam; //ブラシ描画パラメータ 54 | RGBAFix15 rgba_brush; //ブラシ描画時の色 55 | 56 | void (*funcDrawPixel)(TileImage *,int,int,RGBAFix15 *); //ピクセル描画関数 57 | void (*funcColor)(TileImage *,RGBAFix15 *,RGBAFix15 *,void *); //色計算関数 58 | }TileImageDrawInfo; 59 | 60 | 61 | extern TileImageDrawInfo g_tileimage_dinfo; 62 | 63 | void TileImageDrawInfo_clearDrawRect(); 64 | 65 | #endif 66 | -------------------------------------------------------------------------------- /src/include/defWidgets.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************************** 21 | * 全ウィジェットデータの定義 22 | ********************************************/ 23 | 24 | #ifndef DEF_WIDGETS_H 25 | #define DEF_WIDGETS_H 26 | 27 | typedef struct _MainWindow MainWindow; 28 | typedef struct _MainWinCanvas MainWinCanvas; 29 | typedef struct _MainWinCanvasArea MainWinCanvasArea; 30 | typedef struct _DockObject DockObject; 31 | typedef struct _StatusBar StatusBar; 32 | 33 | /** ドックウィジェットのインデックス番号 */ 34 | 35 | enum 36 | { 37 | DOCKWIDGET_TOOL, 38 | DOCKWIDGET_OPTION, 39 | DOCKWIDGET_LAYER, 40 | DOCKWIDGET_BRUSH, 41 | DOCKWIDGET_COLOR, 42 | DOCKWIDGET_COLOR_PALETTE, 43 | DOCKWIDGET_CANVAS_CTRL, 44 | DOCKWIDGET_CANVAS_VIEW, 45 | DOCKWIDGET_IMAGE_VIEWER, 46 | DOCKWIDGET_FILTER_LIST, 47 | DOCKWIDGET_COLOR_WHEEL, 48 | 49 | DOCKWIDGET_NUM 50 | }; 51 | 52 | /** ウィジェット関連データ */ 53 | 54 | typedef struct _WidgetsData 55 | { 56 | MainWindow *mainwin; 57 | mWidget *pane[3]; //パネルのペイン 58 | MainWinCanvas *canvas; 59 | MainWinCanvasArea *canvas_area; 60 | StatusBar *statusbar; 61 | DockObject *dockobj[DOCKWIDGET_NUM]; 62 | 63 | mFont *font_dock, //dock のフォント 64 | *font_dock12px; //dock フォント (12px) 65 | }WidgetsData; 66 | 67 | //--------- 68 | 69 | extern WidgetsData *g_app_widgets; 70 | #define APP_WIDGETS g_app_widgets 71 | 72 | #endif 73 | -------------------------------------------------------------------------------- /src/include/BrushDrawParam.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /****************************** 21 | * ブラシ描画用パラメータ 22 | ******************************/ 23 | 24 | #ifndef BRUSHDRAWPARAM_H 25 | #define BRUSHDRAWPARAM_H 26 | 27 | typedef struct _ImageBuf8 ImageBuf8; 28 | 29 | typedef struct _BrushDrawParam 30 | { 31 | double shape_hard, //円形形状の硬さパラメータ 32 | radius, //半径 (px) 33 | opacity, //最大濃度 [0-1] 34 | min_size, //サイズ最小 [0-1] 35 | min_opacity, //濃度最小 [0-1] 36 | interval_src, //通常ブラシの間隔 37 | interval, //実際の間隔 38 | random_size_min, //ランダムサイズ最小 39 | random_pos_len, //ランダム位置、距離 40 | water_param[3], //水彩 41 | pressure_val[8]; //筆圧補正 作業値 42 | int angle, //角度 [0-511] 43 | angle_random, //角度ランダム幅 44 | rough, //荒さ [0 で無効] 45 | pressure_type; //筆圧補正タイプ 46 | uint32_t flags; 47 | 48 | ImageBuf8 *img_shape, 49 | *img_texture; 50 | }BrushDrawParam; 51 | 52 | 53 | enum 54 | { 55 | BRUSHDP_F_WATER = 1<<0, //水彩 56 | BRUSHDP_F_NO_ANTIALIAS = 1<<1, //非アンチエイリアス 57 | BRUSHDP_F_CURVE = 1<<2, //曲線補間 58 | BRUSHDP_F_RANDOM_SIZE = 1<<3, //ランダムサイズあり 59 | BRUSHDP_F_RANDOM_POS = 1<<4, //ランダム位置あり 60 | BRUSHDP_F_TRAVELLING_DIR = 1<<5, //進行方向 61 | BRUSHDP_F_OVERWRITE_TP = 1<<6, //ブラシ形状の透明部分も上書き 62 | BRUSHDP_F_PRESSURE = 1<<7, //筆圧補正を行うか 63 | BRUSHDP_F_SHAPE_HARD_MAX = 1<<8, //円形形状の硬さは最大 64 | }; 65 | 66 | #endif 67 | -------------------------------------------------------------------------------- /src/include/DockObject.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************************** 21 | * DockObject 22 | ********************************************/ 23 | 24 | #ifndef DOCKOBJECT_H 25 | #define DOCKOBJECT_H 26 | 27 | typedef struct _DockObject DockObject; 28 | typedef struct _mDockWidget mDockWidget; 29 | typedef struct _mDockWidgetState mDockWidgetState; 30 | 31 | struct _DockObject 32 | { 33 | mDockWidget *dockwg; 34 | void (*destroy)(DockObject *); //破棄ハンドラ 35 | mWidget *(*create)(mDockWidget *,int,mWidget *); 36 | }; 37 | 38 | 39 | /*-------*/ 40 | 41 | void DockObject_destroy(DockObject *p); 42 | 43 | DockObject *DockObject_new(int no,int size,uint32_t dock_style, 44 | uint32_t window_style,mDockWidgetState *state, 45 | mWidget *(*func_create)(mDockWidget *,int,mWidget *)); 46 | 47 | void DockObject_showStart(DockObject *p); 48 | mBool DockObject_canDoWidget(DockObject *p); 49 | mBool DockObject_canDoWidget_visible(DockObject *p); 50 | mBool DockObject_canTakeFocus(DockObject *p); 51 | mWindow *DockObject_getOwnerWindow(DockObject *p); 52 | 53 | int DockObject_getDockNo_fromID(int id); 54 | int DockObject_getPaneNo_fromNo(int no); 55 | 56 | void DockObject_relayout_inWindowMode(int dockno); 57 | 58 | void DockObjects_relocate(); 59 | void DockObjects_all_windowMode(int type); 60 | void DockObject_normalize_layout_config(); 61 | 62 | #endif 63 | -------------------------------------------------------------------------------- /src/include/blendcol.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /******************************** 21 | * レイヤの色合成関数 22 | ********************************/ 23 | 24 | #ifndef BLENDCOL_H 25 | #define BLENDCOL_H 26 | 27 | typedef union _RGBFix15 RGBFix15; 28 | typedef void (*BlendColorFunc)(RGBFix15 *,RGBFix15 *); 29 | 30 | void BlendColor_setFuncTable(); 31 | 32 | void BlendColor_normal(RGBFix15 *src,RGBFix15 *dst); 33 | void BlendColor_mul(RGBFix15 *src,RGBFix15 *dst); 34 | void BlendColor_add(RGBFix15 *src,RGBFix15 *dst); 35 | void BlendColor_sub(RGBFix15 *src,RGBFix15 *dst); 36 | void BlendColor_screen(RGBFix15 *src,RGBFix15 *dst); 37 | void BlendColor_overlay(RGBFix15 *src,RGBFix15 *dst); 38 | void BlendColor_hardlight(RGBFix15 *src,RGBFix15 *dst); 39 | void BlendColor_softlight(RGBFix15 *src,RGBFix15 *dst); 40 | void BlendColor_dodge(RGBFix15 *src,RGBFix15 *dst); 41 | void BlendColor_burn(RGBFix15 *src,RGBFix15 *dst); 42 | void BlendColor_linearburn(RGBFix15 *src,RGBFix15 *dst); 43 | void BlendColor_vividlight(RGBFix15 *src,RGBFix15 *dst); 44 | void BlendColor_linearlight(RGBFix15 *src,RGBFix15 *dst); 45 | void BlendColor_pinlight(RGBFix15 *src,RGBFix15 *dst); 46 | void BlendColor_darken(RGBFix15 *src,RGBFix15 *dst); 47 | void BlendColor_lighten(RGBFix15 *src,RGBFix15 *dst); 48 | void BlendColor_difference(RGBFix15 *src,RGBFix15 *dst); 49 | 50 | extern BlendColorFunc g_blendcolfuncs[17]; 51 | 52 | #endif 53 | -------------------------------------------------------------------------------- /mlib/src/private/mAppPrivate.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_APPPRIVATE_H 33 | #define MLIB_APPPRIVATE_H 34 | 35 | #include "mListDef.h" 36 | #include "mTranslation.h" 37 | 38 | typedef struct _mAppRunDat mAppRunDat; 39 | 40 | struct _mAppRunDat 41 | { 42 | mAppRunDat *runBack; 43 | mWindow *modal,*popup; 44 | mBool bQuit; 45 | }; 46 | 47 | struct _mAppPrivate 48 | { 49 | mList listEvent; 50 | 51 | mAppRunDat *runCurrent; 52 | int runLevel; 53 | 54 | mTranslation transDef, 55 | transApp; 56 | const char *trans_filename; 57 | }; 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /mlib/include/mContainerDef.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_CONTAINER_DEF_H 33 | #define MLIB_CONTAINER_DEF_H 34 | 35 | #include "mWidgetDef.h" 36 | 37 | typedef struct 38 | { 39 | int type,gridCols; 40 | uint16_t sepW,gridSepCol,gridSepRow; 41 | mWidgetSpacing padding; 42 | void (*calcHint)(mWidget *); 43 | }mContainerData; 44 | 45 | 46 | struct _mContainer 47 | { 48 | mWidget wg; 49 | mContainerData ct; 50 | }; 51 | 52 | enum MCONTAINER_TYPE 53 | { 54 | MCONTAINER_TYPE_VERT, 55 | MCONTAINER_TYPE_HORZ, 56 | MCONTAINER_TYPE_GRID 57 | }; 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /src/include/MainWindow_pv.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * MainWindow 内部関数 22 | ************************************/ 23 | 24 | #ifndef MAINWINDOW_PV_H 25 | #define MAINWINDOW_PV_H 26 | 27 | typedef struct _MainWindow MainWindow; 28 | 29 | void MainWindow_createToolBar(MainWindow *p,mBool init); 30 | 31 | void MainWindow_layercmd(MainWindow *p,int id); 32 | void MainWindow_filtercmd(int id); 33 | 34 | /* MainWindow_file.c */ 35 | 36 | void MainWindow_setRecentFileMenu(MainWindow *p); 37 | 38 | int MainWindow_runMenu_toolbarDrop_opensave(MainWindow *p,mBool save); 39 | int MainWindow_runMenu_toolbarDrop_savedup(MainWindow *p); 40 | void MainWindow_runMenu_toolbar_recentfile(MainWindow *p); 41 | 42 | /* MainWindow_cmd.c */ 43 | 44 | void MainWindow_pane_layout(MainWindow *p); 45 | void MainWindow_toggle_show_pane_splitter(MainWindow *p); 46 | 47 | void MainWindow_cmd_show_panel_all(MainWindow *p); 48 | void MainWindow_cmd_show_panel_toggle(int no); 49 | 50 | void MainWindow_cmd_changeDPI(MainWindow *p); 51 | void MainWindow_cmd_selectExpand(MainWindow *p); 52 | void MainWindow_cmd_checkMaskState(MainWindow *p); 53 | void MainWindow_cmd_envoption(MainWindow *p); 54 | void MainWindow_cmd_panelLayout(MainWindow *p); 55 | void MainWindow_cmd_resizeCanvas(MainWindow *p); 56 | void MainWindow_cmd_scaleCanvas(MainWindow *p); 57 | void MainWindow_cmd_selectOutputPNG(MainWindow *p); 58 | 59 | #endif 60 | -------------------------------------------------------------------------------- /mlib/src/x11/x11_xinput2.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_X11_XINPUT2_H 33 | #define MLIB_X11_XINPUT2_H 34 | 35 | #if defined(MLIB_ENABLE_PENTABLET) && defined(HAVE_XEXT_XINPUT2) 36 | 37 | #ifdef __cplusplus 38 | extern "C" { 39 | #endif 40 | 41 | int mX11XI2_init(); 42 | 43 | void mX11XI2_pt_selectEvent(Window id); 44 | mBool mX11XI2_pt_grab(Window id,Cursor cursor,int device_id); 45 | void mX11XI2_pt_ungrab(); 46 | 47 | uint32_t mX11XI2_getEventInfo(void *event,double *pressure,mBool *pentablet); 48 | 49 | #ifdef __cplusplus 50 | } 51 | #endif 52 | 53 | #endif 54 | 55 | #endif 56 | -------------------------------------------------------------------------------- /mlib/include/mNanoTime.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_NANOTIME_H 33 | #define MLIB_NANOTIME_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | typedef struct _mNanoTime 40 | { 41 | int64_t sec; 42 | int32_t nsec; 43 | }mNanoTime; 44 | 45 | void mNanoTimeGet(mNanoTime *nt); 46 | void mNanoTimeAdd(mNanoTime *nt,uint64_t nsec); 47 | void mNanoTimeAddMilliSec(mNanoTime *nt,int msec); 48 | int mNanoTimeCompare(mNanoTime *nt1,mNanoTime *nt2); 49 | mBool mNanoTimeSub(mNanoTime *dst,mNanoTime *nt1,mNanoTime *nt2); 50 | 51 | #ifdef __cplusplus 52 | } 53 | #endif 54 | 55 | #endif 56 | -------------------------------------------------------------------------------- /mlib/src/private/mEventList.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (c) 2017, Azel 3 | All rights reserved. 4 | 5 | Redistribution and use in source and binary forms, with or without 6 | modification, are permitted provided that the following conditions are met: 7 | 8 | 1. Redistributions of source code must retain the above copyright notice, 9 | this list of conditions and the following disclaimer. 10 | 11 | 2. Redistributions in binary form must reproduce the above copyright notice, 12 | this list of conditions and the following disclaimer in the documentation 13 | and/or other materials provided with the distribution. 14 | 15 | 3. Neither the name of the copyright holder nor the names of its contributors 16 | may be used to endorse or promote products derived from this software 17 | without specific prior written permission. 18 | 19 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERSAND CONTRIBUTORS "AS IS" AND 20 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, 21 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 22 | ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 23 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, 24 | OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 | OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 | WHETHER IN CONTRACT, STRICT LIABILITY, 28 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 | $*/ 31 | 32 | #ifndef MLIB_EVENTLIST_H 33 | #define MLIB_EVENTLIST_H 34 | 35 | #ifdef __cplusplus 36 | extern "C" { 37 | #endif 38 | 39 | void mEventListEmpty(void); 40 | mBool mEventListPending(void); 41 | 42 | void mEventListAppend(mEvent *ev); 43 | mEvent *mEventListAppend_widget(mWidget *widget,int type); 44 | mEvent *mEventListAppend_only(mWidget *widget,int type); 45 | mBool mEventListGetEvent(mEvent *ev); 46 | void mEventListDeleteWidget(mWidget *widget); 47 | mBool mEventListDeleteLastEvent(mWidget *wg,int type); 48 | 49 | #ifdef __cplusplus 50 | } 51 | #endif 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /src/include/MainWinCanvas.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * MainWinCanvas 関数 22 | ************************************/ 23 | 24 | #ifndef MAINWINCANVAS_H 25 | #define MAINWINCANVAS_H 26 | 27 | /* MainWinCanvas */ 28 | 29 | void MainWinCanvas_new(mWidget *parent); 30 | void MainWinCanvas_setScrollInfo(); 31 | void MainWinCanvas_setScrollPos(); 32 | 33 | /* MainWinCanvasArea */ 34 | 35 | void MainWinCanvasArea_setTimer_updateArea(int time); 36 | void MainWinCanvasArea_clearTimer_updateArea(); 37 | 38 | void MainWinCanvasArea_setTimer_updateRect(mBox *boximg); 39 | void MainWinCanvasArea_clearTimer_updateRect(mBool update); 40 | 41 | void MainWinCanvasArea_setTimer_updateMove(); 42 | void MainWinCanvasArea_clearTimer_updateMove(); 43 | 44 | void MainWinCanvasArea_setTimer_updateSelectMove(); 45 | void MainWinCanvasArea_clearTimer_updateSelectMove(); 46 | 47 | void MainWinCanvasArea_setTimer_updateSelectImageMove(); 48 | mBool MainWinCanvasArea_clearTimer_updateSelectImageMove(); 49 | 50 | void MainWinCanvasArea_setTimer_scroll(mPoint *ptdir); 51 | void MainWinCanvasArea_clearTimer_scroll(mPoint *ptsum); 52 | 53 | void MainWinCanvasArea_changeDrawCursor(); 54 | void MainWinCanvasArea_setCursor_forTool(); 55 | void MainWinCanvasArea_setCursor(int no); 56 | void MainWinCanvasArea_setCursor_wait(); 57 | void MainWinCanvasArea_restoreCursor(); 58 | 59 | mBool MainWinCanvasArea_isPressKey_space(); 60 | int MainWinCanvasArea_getPressRawKey(); 61 | 62 | #endif 63 | -------------------------------------------------------------------------------- /src/include/MainWindow.h: -------------------------------------------------------------------------------- 1 | /*$ 2 | Copyright (C) 2013-2017 Azel. 3 | 4 | This file is part of AzPainter. 5 | 6 | AzPainter is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | AzPainter is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see . 18 | $*/ 19 | 20 | /************************************ 21 | * MainWindow 関数 22 | ************************************/ 23 | 24 | #ifndef MAINWINDOW_H 25 | #define MAINWINDOW_H 26 | 27 | typedef struct _MainWindow MainWindow; 28 | typedef struct _LayerItem LayerItem; 29 | 30 | enum 31 | { 32 | MAINWINDOW_SAVEFILE_OVERWRITE, 33 | MAINWINDOW_SAVEFILE_RENAME, 34 | MAINWINDOW_SAVEFILE_DUP 35 | }; 36 | 37 | 38 | void MainWindow_new(); 39 | void MainWindow_showStart(MainWindow *p); 40 | 41 | void MainWindow_quit(); 42 | 43 | void MainWindow_setTitle(MainWindow *p); 44 | void MainWindow_apperr(int err,const char *detail); 45 | mBool MainWindow_confirmSave(MainWindow *p); 46 | void MainWindow_updateNewCanvas(MainWindow *p,const char *filename); 47 | 48 | void MainWindow_getProgressBarPos(mPoint *pt); 49 | 50 | void MainWindow_newImage(MainWindow *p); 51 | void MainWindow_openFile(MainWindow *p,int recentno); 52 | mBool MainWindow_loadImage(MainWindow *p,const char *filename,int loadopt); 53 | mBool MainWindow_saveFile(MainWindow *p,int savetype,int recentno); 54 | 55 | void MainWindow_undoredo(MainWindow *p,mBool redo); 56 | void MainWindow_onCanvasKeyCommand(int cmdid); 57 | 58 | void MainWindow_layer_new_dialog(MainWindow *p,LayerItem *pi_above); 59 | void MainWindow_layer_setoption(MainWindow *p,LayerItem *pi); 60 | void MainWindow_layer_setcolor(MainWindow *p,LayerItem *pi); 61 | void MainWindow_layer_settype(MainWindow *p,LayerItem *pi); 62 | 63 | #endif 64 | --------------------------------------------------------------------------------