2007-07-01 04:23:57 +02:00
|
|
|
// Copyright (c) 2007, Rodrigo Braz Monteiro
|
|
|
|
// All rights reserved.
|
|
|
|
//
|
|
|
|
// Redistribution and use in source and binary forms, with or without
|
|
|
|
// modification, are permitted provided that the following conditions are met:
|
|
|
|
//
|
|
|
|
// * Redistributions of source code must retain the above copyright notice,
|
|
|
|
// this list of conditions and the following disclaimer.
|
|
|
|
// * Redistributions in binary form must reproduce the above copyright notice,
|
|
|
|
// this list of conditions and the following disclaimer in the documentation
|
|
|
|
// and/or other materials provided with the distribution.
|
|
|
|
// * Neither the name of the Aegisub Group nor the names of its contributors
|
|
|
|
// may be used to endorse or promote products derived from this software
|
|
|
|
// without specific prior written permission.
|
|
|
|
//
|
|
|
|
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
|
|
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
|
|
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
|
|
// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
|
|
|
// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
|
|
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
|
|
// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
|
|
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
|
|
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
|
|
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
|
|
// POSSIBILITY OF SUCH DAMAGE.
|
|
|
|
//
|
2009-07-29 07:43:02 +02:00
|
|
|
// Aegisub Project http://www.aegisub.org/
|
2007-07-01 04:23:57 +02:00
|
|
|
//
|
2009-07-29 07:43:02 +02:00
|
|
|
// $Id$
|
|
|
|
|
|
|
|
/// @file visual_tool_rotatez.cpp
|
|
|
|
/// @brief 2D rotation in Z axis visual typesetting tool
|
|
|
|
/// @ingroup visual_ts
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
|
|
|
|
|
|
|
|
///////////
|
|
|
|
// Headers
|
2009-01-04 07:31:48 +01:00
|
|
|
#include "config.h"
|
|
|
|
|
2007-07-01 04:23:57 +02:00
|
|
|
#include "ass_dialogue.h"
|
2009-09-10 15:06:40 +02:00
|
|
|
#include "ass_file.h"
|
|
|
|
#include "subs_edit_box.h"
|
|
|
|
#include "subs_grid.h"
|
2007-07-01 04:23:57 +02:00
|
|
|
#include "utils.h"
|
2009-09-10 03:41:34 +02:00
|
|
|
#include "video_display.h"
|
2009-09-10 15:06:40 +02:00
|
|
|
#include "visual_tool_rotatez.h"
|
2007-07-01 04:23:57 +02:00
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Constructor
|
|
|
|
/// @param _parent
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
VisualToolRotateZ::VisualToolRotateZ(VideoDisplay *_parent)
|
|
|
|
: VisualTool(_parent)
|
|
|
|
{
|
|
|
|
_parent->ShowCursor(false);
|
2007-07-27 06:50:15 +02:00
|
|
|
DoRefresh();
|
2007-07-01 04:23:57 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Update
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
void VisualToolRotateZ::Update() {
|
|
|
|
// Render parent
|
|
|
|
GetParent()->Render();
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Draw
|
|
|
|
/// @return
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
void VisualToolRotateZ::Draw() {
|
|
|
|
// Get line to draw
|
|
|
|
AssDialogue *line = GetActiveDialogueLine();
|
|
|
|
if (!line) return;
|
|
|
|
|
2007-07-04 23:47:26 +02:00
|
|
|
// Draw pivot
|
|
|
|
DrawAllFeatures();
|
|
|
|
|
2007-07-01 04:23:57 +02:00
|
|
|
// Radius
|
|
|
|
int dx=0,dy=0;
|
2007-07-04 23:47:26 +02:00
|
|
|
if (dragging) GetLinePosition(line,dx,dy);
|
|
|
|
else GetLinePosition(line,dx,dy,orgx,orgy);
|
2007-07-01 04:23:57 +02:00
|
|
|
int radius = (int) sqrt(double((dx-orgx)*(dx-orgx)+(dy-orgy)*(dy-orgy)));
|
|
|
|
int oRadius = radius;
|
|
|
|
if (radius < 50) radius = 50;
|
|
|
|
|
|
|
|
// Pivot coordinates
|
|
|
|
int odx = dx;
|
|
|
|
int ody = dy;
|
|
|
|
dx = orgx;
|
|
|
|
dy = orgy;
|
|
|
|
|
|
|
|
// Rotation
|
|
|
|
float rz;
|
|
|
|
GetLineRotation(line,rx,ry,rz);
|
|
|
|
if (line == curDiag) rz = curAngle;
|
|
|
|
|
|
|
|
// Get scale
|
|
|
|
float scalX = 100.0f;
|
|
|
|
float scalY = 100.0f;
|
|
|
|
GetLineScale(line,scalX,scalY);
|
|
|
|
|
|
|
|
// Get deltas
|
|
|
|
int deltax = int(cos(rz*3.1415926536/180.0)*radius);
|
|
|
|
int deltay = int(-sin(rz*3.1415926536/180.0)*radius);
|
|
|
|
|
|
|
|
// Set colours
|
|
|
|
SetLineColour(colour[0]);
|
|
|
|
SetFillColour(colour[1],0.3f);
|
|
|
|
|
|
|
|
// Set up the projection
|
|
|
|
glMatrixMode(GL_MODELVIEW);
|
|
|
|
glPushMatrix();
|
|
|
|
glLoadIdentity();
|
|
|
|
glTranslatef(dx,dy,-1.0f);
|
|
|
|
float matrix[16] = { 2500, 0, 0, 0, 0, 2500, 0, 0, 0, 0, 1, 1, 0, 0, 2500, 2500 };
|
|
|
|
glMultMatrixf(matrix);
|
|
|
|
glScalef(1.0f,1.0f,8.0f);
|
|
|
|
glRotatef(ry,0.0f,-1.0f,0.0f);
|
|
|
|
glRotatef(rx,-1.0f,0.0f,0.0f);
|
|
|
|
glScalef(scalX/100.0f,scalY/100.0f,1.0f);
|
|
|
|
|
|
|
|
// Draw the circle
|
|
|
|
DrawRing(0,0,radius+4,radius-4);
|
|
|
|
|
|
|
|
// Draw markers around circle
|
|
|
|
int markers = 6;
|
|
|
|
float markStart = -90.0f / markers;
|
|
|
|
float markEnd = markStart+(180.0f/markers);
|
|
|
|
for (int i=0;i<markers;i++) {
|
|
|
|
float angle = i*(360.0f/markers);
|
|
|
|
DrawRing(0,0,radius+30,radius+12,radius/radius,angle+markStart,angle+markEnd);
|
|
|
|
}
|
|
|
|
|
|
|
|
// Draw the baseline
|
|
|
|
SetLineColour(colour[3],1.0f,2);
|
|
|
|
DrawLine(deltax,deltay,-deltax,-deltay);
|
|
|
|
|
|
|
|
// Draw the connection line
|
|
|
|
if (orgx != odx && orgy != ody) {
|
|
|
|
double angle = atan2(double(dy-ody),double(odx-dx)) + rz*3.1415926536/180.0;
|
|
|
|
int fx = int(cos(angle)*oRadius);
|
|
|
|
int fy = -int(sin(angle)*oRadius);
|
|
|
|
DrawLine(0,0,fx,fy);
|
|
|
|
int mdx = int(cos(rz*3.1415926536/180.0)*20);
|
|
|
|
int mdy = int(-sin(rz*3.1415926536/180.0)*20);
|
2007-07-01 04:46:12 +02:00
|
|
|
DrawLine(fx-mdx,fy-mdy,fx+mdx,fy+mdy);
|
2007-07-01 04:23:57 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// Draw the rotation line
|
|
|
|
SetLineColour(colour[0],1.0f,1);
|
|
|
|
SetFillColour(colour[1],0.3f);
|
|
|
|
DrawCircle(deltax,deltay,4);
|
|
|
|
|
|
|
|
// Restore
|
|
|
|
glPopMatrix();
|
|
|
|
|
|
|
|
// Draw line to mouse
|
2007-07-04 23:47:26 +02:00
|
|
|
if (mouseX != -1 && !dragging && GetHighlightedFeature() == -1) {
|
2007-07-01 04:23:57 +02:00
|
|
|
SetLineColour(colour[0]);
|
|
|
|
DrawLine(dx,dy,mx,my);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Start holding
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
void VisualToolRotateZ::InitializeHold() {
|
|
|
|
GetLinePosition(curDiag,odx,ody,orgx,orgy);
|
|
|
|
startAngle = atan2(double(orgy-mouseY*sh/h),double(mouseX*sw/w-orgx)) * 180.0 / 3.1415926535897932;
|
|
|
|
GetLineRotation(curDiag,rx,ry,origAngle);
|
|
|
|
curAngle = origAngle;
|
|
|
|
curDiag->StripTag(_T("\\frz"));
|
|
|
|
curDiag->StripTag(_T("\\fr"));
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Update hold
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
void VisualToolRotateZ::UpdateHold() {
|
|
|
|
// Find angle
|
|
|
|
float screenAngle = atan2(double(orgy-mouseY*sh/h),double(mouseX*sw/w-orgx)) * 180.0 / 3.1415926535897932;
|
|
|
|
curAngle = screenAngle - startAngle + origAngle;
|
|
|
|
while (curAngle < 0.0f) curAngle += 360.0f;
|
|
|
|
while (curAngle >= 360.0f) curAngle -= 360.0f;
|
|
|
|
|
|
|
|
// Snap
|
|
|
|
if (shiftDown) {
|
|
|
|
curAngle = (float)((int)((curAngle+15.0f)/30.0f))*30.0f;
|
|
|
|
if (curAngle == 360.0f) curAngle = 0.0f;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Commit hold
|
|
|
|
///
|
2007-07-01 04:23:57 +02:00
|
|
|
void VisualToolRotateZ::CommitHold() {
|
2007-07-01 05:57:34 +02:00
|
|
|
SetOverride(_T("\\frz"),PrettyFloat(wxString::Format(_T("(%0.3f)"),curAngle)));
|
2007-07-01 04:23:57 +02:00
|
|
|
}
|
2007-07-04 23:47:26 +02:00
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
2009-07-30 05:36:53 +02:00
|
|
|
/// @brief Get \\org pivot
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
///
|
2007-07-04 23:47:26 +02:00
|
|
|
void VisualToolRotateZ::PopulateFeatureList() {
|
|
|
|
// Get line
|
|
|
|
curDiag = GetActiveDialogueLine();
|
|
|
|
GetLinePosition(curDiag,odx,ody,orgx,orgy);
|
|
|
|
|
|
|
|
// Set features
|
|
|
|
features.resize(1);
|
|
|
|
VisualDraggableFeature &feat = features.back();
|
|
|
|
feat.x = orgx;
|
|
|
|
feat.y = orgy;
|
|
|
|
feat.line = curDiag;
|
|
|
|
feat.type = DRAG_BIG_TRIANGLE;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
2009-07-30 05:36:53 +02:00
|
|
|
/// @brief Update dragging of \\org
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
/// @param feature
|
|
|
|
///
|
2007-07-04 23:47:26 +02:00
|
|
|
void VisualToolRotateZ::UpdateDrag(VisualDraggableFeature &feature) {
|
|
|
|
orgx = feature.x;
|
|
|
|
orgy = feature.y;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
2009-07-30 05:36:53 +02:00
|
|
|
/// @brief Commit dragging of \\org
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
/// @param feature
|
|
|
|
///
|
2007-07-04 23:47:26 +02:00
|
|
|
void VisualToolRotateZ::CommitDrag(VisualDraggableFeature &feature) {
|
|
|
|
SetOverride(_T("\\org"),wxString::Format(_T("(%i,%i)"),feature.x,feature.y));
|
|
|
|
}
|
2007-07-27 06:50:15 +02:00
|
|
|
|
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|
|
|
|
/// @brief Refresh
|
|
|
|
///
|
2007-07-27 06:50:15 +02:00
|
|
|
void VisualToolRotateZ::DoRefresh() {
|
|
|
|
AssDialogue *line = GetActiveDialogueLine();
|
|
|
|
GetLinePosition(line,odx,ody,orgx,orgy);
|
|
|
|
GetLineRotation(line,rx,ry,curAngle);
|
|
|
|
}
|
2009-07-29 07:43:02 +02:00
|
|
|
|
Note: This was done using a script! it's far from perfect but 95% of the work has been done already formatting-wise.
Document all functions, class, struct, union, enum, macro, variable, typedefs. This isn't the actual document in itself but empty documentation using any old documentation if it was there.
This was done using exuberant ctags to get tag info, then a TCL script to parse/remove old comments and convert them into Doxygen-style.
Some notes:
* Anything labeled 'DOCME' needs to be documented, @param and @return have been left blank as it would be annoying to delete the 'DOCME' from every one of those.
* Some multiline comments may have been munged into single line comments
* Leave the /// comments above global variables with a space, if they're harder to read then we'll be less likey to use them.
* Enum comments can go after the enumeration itself '[value] /// comment'
* include/aegisub/*.h haven't been converted yet, this will be done in a later commit
* Some documentation blocks are in the wrong place, in the .h when it should be in the .cpp, or vice versa.
See http://devel.aegisub.org/wiki/Doxygen for some details on Doxygen and a 'style guide'.
Originally committed to SVN as r3312.
2009-07-30 00:59:22 +02:00
|
|
|
|