diff --git a/install/readme.txt b/install/readme.txt index e2c0cddd..7e095289 100644 --- a/install/readme.txt +++ b/install/readme.txt @@ -1,4 +1,4 @@ -MUSHclient version 4.75 +MUSHclient version 4.76 ======================= Sunday, 12th June 2011 diff --git a/scripting/lua_methods.cpp b/scripting/lua_methods.cpp index 30068f3f..c045ac05 100644 --- a/scripting/lua_methods.cpp +++ b/scripting/lua_methods.cpp @@ -4090,14 +4090,15 @@ static int L_Help (lua_State *L) static int L_Hyperlink (lua_State *L) { CMUSHclientDoc *pDoc = doc (L); - pDoc->Hyperlink ( - my_checkstring (L, 1), // Action - my_checkstring (L, 2), // Text - my_checkstring (L, 3), // Hint - my_checkstring (L, 4), // TextColour - my_checkstring (L, 5), // BackColour - optboolean (L, 6, 0) // URL - optional - ); + pDoc->Hyperlink_Helper ( + my_checkstring (L, 1), // Action + my_checkstring (L, 2), // Text + my_checkstring (L, 3), // Hint + my_checkstring (L, 4), // TextColour + my_checkstring (L, 5), // BackColour + optboolean (L, 6, 0), // URL - optional + optboolean (L, 7, 0) // No_Underline - optional + ); return 0; // number of result fields } // end of L_Hyperlink diff --git a/scripting/methods/methods_noting.cpp b/scripting/methods/methods_noting.cpp index 50a81c15..ade0a14f 100644 --- a/scripting/methods/methods_noting.cpp +++ b/scripting/methods/methods_noting.cpp @@ -512,12 +512,14 @@ else */ -void CMUSHclientDoc::Hyperlink(LPCTSTR Action, - LPCTSTR Text, - LPCTSTR Hint, - LPCTSTR TextColour, - LPCTSTR BackColour, - BOOL URL) +void CMUSHclientDoc::Hyperlink_Helper (LPCTSTR Action, + LPCTSTR Text, + LPCTSTR Hint, + LPCTSTR TextColour, + LPCTSTR BackColour, + BOOL URL, + BOOL NoUnderline) + { // return if attempt to do tell (or note) before output buffer exists if (m_pCurrentLine == NULL || m_pLinePositions == NULL) @@ -560,7 +562,7 @@ void CMUSHclientDoc::Hyperlink(LPCTSTR Action, // change to underlined hyperlink AddStyle (COLOUR_RGB | (URL ? ACTION_HYPERLINK : ACTION_SEND) | - UNDERLINE, + (NoUnderline ? 0 : UNDERLINE), forecolour, backcolour, 0, GetAction (Action, @@ -590,7 +592,26 @@ void CMUSHclientDoc::Hyperlink(LPCTSTR Action, AddStyle (COLOUR_CUSTOM, m_iNoteTextColour, BLACK, 0, NULL); } // not RGB -} // end of CMUSHclientDoc::Hyperlink +} // end of CMUSHclientDoc::Hyperlink_Helper + + +void CMUSHclientDoc::Hyperlink(LPCTSTR Action, + LPCTSTR Text, + LPCTSTR Hint, + LPCTSTR TextColour, + LPCTSTR BackColour, + BOOL URL) + { + + Hyperlink_Helper (Action, + Text, + Hint, + TextColour, + BackColour, + URL, + FALSE); + } // end of CMUSHclientDoc::Hyperlink + /*