You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
(67) |
Apr
(455) |
May
(202) |
Jun
(136) |
Jul
(203) |
Aug
(60) |
Sep
(88) |
Oct
(64) |
Nov
(56) |
Dec
(78) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(271) |
Feb
(207) |
Mar
|
Apr
|
May
(167) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Foster B. <fos...@us...> - 2006-02-03 18:34:24
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/sources/win32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/begin/sources/win32 Modified Files: main.cpp Log Message: asl 1.0.13 Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/sources/win32/main.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** main.cpp 24 Jan 2006 19:38:51 -0000 1.1 --- main.cpp 3 Feb 2006 18:33:39 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ *************** *** 42,62 **** enum { ! ADOBE_ABOUT = 40001, ! ADOBE_QUIT, ! ADOBE_REFRESH_VIEW, ! ADOBE_REFRESH_SHEET, ! ADOBE_NORMAL_DIALOG_SIZE, ! ADOBE_SMALL_DIALOG_SIZE, ! ADOBE_MINI_DIALOG_SIZE, ! ADOBE_SHOW_WIDGET_FRAMES, ! ADOBE_CLEAR_WIDGET_FRAMES, ! ADOBE_SERIALIZE_WIDGETS, ! ADOBE_RUN_MODAL, ! ADOBE_LOCALIZATION_ENUS, ! ADOBE_LOCALIZATION_DEDE, ! ADOBE_LOCALIZATION_JAJP, ! ADOBE_LOCALIZATION_KOKR, ! ADOBE_LOCALIZATION_PGPG }; --- 42,62 ---- enum { ! ADOBE_ABOUT = 40001, ! ADOBE_QUIT, ! ADOBE_REFRESH_VIEW, ! ADOBE_REFRESH_SHEET, ! ADOBE_NORMAL_DIALOG_SIZE, ! ADOBE_SMALL_DIALOG_SIZE, ! ADOBE_MINI_DIALOG_SIZE, ! ADOBE_SHOW_WIDGET_FRAMES, ! ADOBE_CLEAR_WIDGET_FRAMES, ! ADOBE_SERIALIZE_WIDGETS, ! ADOBE_RUN_MODAL, ! ADOBE_LOCALIZATION_ENUS, ! ADOBE_LOCALIZATION_DEDE, ! ADOBE_LOCALIZATION_JAJP, ! ADOBE_LOCALIZATION_KOKR, ! ADOBE_LOCALIZATION_PGPG }; *************** *** 65,75 **** void clip_quotes(std::string& str) { ! // ! // Sometimes GetCommandLine puts double quotes at the beginning and ! // end of the command line (this doesn't always happen, not if the ! // program was started from the prompt instead of the GUI). ! // ! if( str[0] == '"' ) ! str = str.substr( 1, str.size() - 2 ); } --- 65,75 ---- void clip_quotes(std::string& str) { ! // ! // Sometimes GetCommandLine puts double quotes at the beginning and ! // end of the command line (this doesn't always happen, not if the ! // program was started from the prompt instead of the GUI). ! // ! if( str[0] == '"' ) ! str = str.substr( 1, str.size() - 2 ); } *************** *** 78,88 **** void open_document(adobe::application_t* app, const std::string& filename) { ! boost::filesystem::path file( filename, boost::filesystem::native ); ! std::string extension( boost::filesystem::extension( file ) ); ! if ( extension == ".eve") ! app->set_eve_file( file ); ! else if ( extension == ".adm") ! app->set_adam_file( file ); } --- 78,88 ---- void open_document(adobe::application_t* app, const std::string& filename) { ! boost::filesystem::path file( filename, boost::filesystem::native ); ! std::string extension( boost::filesystem::extension( file ) ); ! if ( extension == ".eve") ! app->set_eve_file( file ); ! else if ( extension == ".adm") ! app->set_adam_file( file ); } *************** *** 100,250 **** /// Main window event handler /// ! /// \param window the window associated with the event. ! /// \param message the Windows event type. ! /// \param wParam the pointer parameter. ! /// \param lParam the integer parameter. /// ! /// \return zero, or whatever the default window handler returns. // LRESULT CALLBACK main_window_proc(HWND window, UINT message, WPARAM wParam, LPARAM lParam) { ! application_t* app(hackery::cast<application_t*>(::GetWindowLongPtr(window, GWLP_USERDATA))); ! bool handled(true); ! if (message == WM_CLOSE) ! { ! ::PostQuitMessage(0); ! } ! if (message == WM_COMMAND) ! { ! //HMENU menu(::GetMenu(window)); ! WORD command(LOWORD(wParam)); ! switch(command) ! { ! case ADOBE_ABOUT: ! ::MessageBox(NULL, _T("Adobe Begin Copyright 2005-2006 Adobe Systems Incorporated"), _T("About Adobe Begin"), MB_OK); ! break; ! case ADOBE_QUIT: ! ::PostQuitMessage(0); ! break; ! case ADOBE_REFRESH_VIEW: ! app->display_window(); ! break; ! case ADOBE_REFRESH_SHEET: ! app->load_sheet(); ! break; ! case ADOBE_NORMAL_DIALOG_SIZE: ! app->set_dialog_size( size_normal_s ); ! app->display_window(); ! break; ! case ADOBE_SMALL_DIALOG_SIZE: ! app->set_dialog_size( size_small_s ); ! app->display_window(); ! break; ! case ADOBE_MINI_DIALOG_SIZE: ! app->set_dialog_size( size_mini_s ); ! app->display_window(); ! break; #ifndef NDEBUG ! case ADOBE_SHOW_WIDGET_FRAMES: ! app->frame_window(); ! break; ! case ADOBE_CLEAR_WIDGET_FRAMES: ! app->clear_window_frames(); ! break; #else ! case ADOBE_SHOW_WIDGET_FRAMES: ! case ADOBE_CLEAR_WIDGET_FRAMES: ! system_beep(); ! break; #endif ! case ADOBE_SERIALIZE_WIDGETS: ! app->serialize_connections(); ! break; ! case ADOBE_RUN_MODAL: ! app->run_current_as_modal(); ! break; ! case ADOBE_LOCALIZATION_ENUS: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("en-us"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_DEDE: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("de-de"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_JAJP: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("ja-jp"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_KOKR: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("ko-kr"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_PGPG: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("pg-pg"))); ! app->display_window(); ! break; ! default: ! handled = false; ! } ! } ! else if (message == WM_DROPFILES) ! { ! HDROP drop(reinterpret_cast<HDROP>(wParam)); ! UINT numfiles(::DragQueryFile(drop, 0xFFFFFFFF, NULL, 0)); ! for (UINT i(0); i < numfiles; ++i) ! { ! UINT size_needed(::DragQueryFile(drop, i, NULL, 0)); ! std::string buffer(size_needed + 1, 0); ! ::DragQueryFileA(drop, i, &buffer[0], size_needed + 1); ! std::string temp(&buffer[0]); ! if (temp.rfind(".adm") == temp.size() - 4) ! app->set_adam_file(boost::filesystem::path(temp.c_str(), boost::filesystem::native)); ! else if (temp.rfind(".eve") == temp.size() - 4) ! app->set_eve_file(boost::filesystem::path(temp.c_str(), boost::filesystem::native)); ! } ! ::DragFinish(drop); ! app->load_sheet(); ! } ! else if (message == WM_DESTROY) ! { ! } ! else ! { ! handled = false; ! } ! // ! // Pass it to the default window procedure if we haven't handled it. ! // ! return handled ? 0 : DefWindowProcW(window, message, wParam, lParam); } --- 100,250 ---- /// Main window event handler /// ! /// \param window the window associated with the event. ! /// \param message the Windows event type. ! /// \param wParam the pointer parameter. ! /// \param lParam the integer parameter. /// ! /// \return zero, or whatever the default window handler returns. // LRESULT CALLBACK main_window_proc(HWND window, UINT message, WPARAM wParam, LPARAM lParam) { ! application_t* app(hackery::cast<application_t*>(::GetWindowLongPtr(window, GWLP_USERDATA))); ! bool handled(true); ! if (message == WM_CLOSE) ! { ! ::PostQuitMessage(0); ! } ! if (message == WM_COMMAND) ! { ! //HMENU menu(::GetMenu(window)); ! WORD command(LOWORD(wParam)); ! switch(command) ! { ! case ADOBE_ABOUT: ! ::MessageBox(NULL, _T("Adobe Begin Copyright 2005-2006 Adobe Systems Incorporated"), _T("About Adobe Begin"), MB_OK); ! break; ! case ADOBE_QUIT: ! ::PostQuitMessage(0); ! break; ! case ADOBE_REFRESH_VIEW: ! app->display_window(); ! break; ! case ADOBE_REFRESH_SHEET: ! app->load_sheet(); ! break; ! case ADOBE_NORMAL_DIALOG_SIZE: ! app->set_dialog_size( size_normal_s ); ! app->display_window(); ! break; ! case ADOBE_SMALL_DIALOG_SIZE: ! app->set_dialog_size( size_small_s ); ! app->display_window(); ! break; ! case ADOBE_MINI_DIALOG_SIZE: ! app->set_dialog_size( size_mini_s ); ! app->display_window(); ! break; #ifndef NDEBUG ! case ADOBE_SHOW_WIDGET_FRAMES: ! app->frame_window(); ! break; ! case ADOBE_CLEAR_WIDGET_FRAMES: ! app->clear_window_frames(); ! break; #else ! case ADOBE_SHOW_WIDGET_FRAMES: ! case ADOBE_CLEAR_WIDGET_FRAMES: ! system_beep(); ! break; #endif ! case ADOBE_SERIALIZE_WIDGETS: ! app->serialize_connections(); ! break; ! case ADOBE_RUN_MODAL: ! app->run_current_as_modal(); ! break; ! case ADOBE_LOCALIZATION_ENUS: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("en-us"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_DEDE: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("de-de"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_JAJP: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("ja-jp"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_KOKR: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("ko-kr"))); ! app->display_window(); ! break; ! case ADOBE_LOCALIZATION_PGPG: ! adobe::implementation::top_frame().attribute_set_m.insert( ! std::make_pair(adobe::static_token_range("lang"), adobe::static_token_range("pg-pg"))); ! app->display_window(); ! break; ! default: ! handled = false; ! } ! } ! else if (message == WM_DROPFILES) ! { ! HDROP drop(reinterpret_cast<HDROP>(wParam)); ! UINT numfiles(::DragQueryFile(drop, 0xFFFFFFFF, NULL, 0)); ! for (UINT i(0); i < numfiles; ++i) ! { ! UINT size_needed(::DragQueryFile(drop, i, NULL, 0)); ! std::string buffer(size_needed + 1, 0); ! ::DragQueryFileA(drop, i, &buffer[0], size_needed + 1); ! std::string temp(&buffer[0]); ! if (temp.rfind(".adm") == temp.size() - 4) ! app->set_adam_file(boost::filesystem::path(temp.c_str(), boost::filesystem::native)); ! else if (temp.rfind(".eve") == temp.size() - 4) ! app->set_eve_file(boost::filesystem::path(temp.c_str(), boost::filesystem::native)); ! } ! ::DragFinish(drop); ! app->load_sheet(); ! } ! else if (message == WM_DESTROY) ! { ! } ! else ! { ! handled = false; ! } ! // ! // Pass it to the default window procedure if we haven't handled it. ! // ! return handled ? 0 : DefWindowProcW(window, message, wParam, lParam); } *************** *** 253,328 **** void setup_main_window( application_t* app ) { ! // INIT ONCE all this stuff! ! INITCOMMONCONTROLSEX control_info = { sizeof(INITCOMMONCONTROLSEX), 0x0000FFFF }; ! ::InitCommonControlsEx(&control_info); ! WNDCLASSW wc; ! const wchar_t* window_class(L"adobe_begin_main_window"); ! wc.style = CS_HREDRAW | CS_VREDRAW; ! wc.lpfnWndProc = main_window_proc; ! wc.cbClsExtra = 0; ! wc.cbWndExtra = 0; ! wc.hInstance = ::GetModuleHandle(NULL); ! wc.hIcon = LoadIcon(wc.hInstance, MAKEINTRESOURCE(RES_APP_ICON)); ! wc.hCursor = LoadCursor(0, IDC_ARROW); ! wc.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1); ! wc.lpszMenuName = window_class; ! wc.lpszClassName = window_class; ! RegisterClassW(&wc); ! HWND root_window = ::CreateWindowExW( WS_EX_WINDOWEDGE | WS_EX_DLGMODALFRAME | WS_EX_COMPOSITED, ! window_class, L"Adobe Begin", ! WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU, ! 10, 10, 640, 100, NULL, ::CreateMenu(), ! ::GetModuleHandle(NULL), ! NULL); ! if (root_window == NULL) throw std::runtime_error("Could not open main window"); ! ::ShowWindow(root_window, SW_NORMAL); ! ::DragAcceptFiles(root_window, TRUE); ! ::SetWindowLongPtrA(root_window, GWLP_USERDATA, hackery::cast<LONG>(app)); ! // setup the menu system ! HMENU menu_bar(::GetMenu(root_window)); ! HMENU app_menu(::CreatePopupMenu()); ! HMENU view_options_menu(::CreatePopupMenu()); ! HMENU localization_menu(::CreatePopupMenu()); ! ::AppendMenu(app_menu, MF_STRING, ADOBE_ABOUT, _T("&About Adobe Begin")); ! ::AppendMenu(app_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(app_menu, MF_STRING, ADOBE_QUIT, _T("&Quit Adobe Begin")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_REFRESH_VIEW, _T("&Refresh View")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_REFRESH_SHEET, _T("R&efresh Sheet")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_NORMAL_DIALOG_SIZE, _T("&Normal Dialog Size")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SMALL_DIALOG_SIZE, _T("&Small Dialog Size")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_MINI_DIALOG_SIZE, _T("&Mini Dialog Size")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SHOW_WIDGET_FRAMES, _T("&Show Widget Frames")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_CLEAR_WIDGET_FRAMES, _T("&Clear Widget Frames")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SERIALIZE_WIDGETS, _T("&Serialize Widgets")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_RUN_MODAL, _T("&Run Modal")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_ENUS, _T("&Standard English (en-us)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_DEDE, _T("&German (de-de)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_JAJP, _T("&Japanese (ja-jp)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_KOKR, _T("&Korean (ko-kr)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_PGPG, _T("&Pig Latin (pg-pg)")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(app_menu), _T("&Adobe Begin")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(view_options_menu), _T("&View Options")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(localization_menu), _T("&Localization")); ! ::DrawMenuBar(root_window); ! // set root in display ! adobe::get_main_display().set_root(root_window); } --- 253,328 ---- void setup_main_window( application_t* app ) { ! // INIT ONCE all this stuff! ! INITCOMMONCONTROLSEX control_info = { sizeof(INITCOMMONCONTROLSEX), 0x0000FFFF }; ! ::InitCommonControlsEx(&control_info); ! WNDCLASSW wc; ! const wchar_t* window_class(L"adobe_begin_main_window"); ! wc.style = CS_HREDRAW | CS_VREDRAW; ! wc.lpfnWndProc = main_window_proc; ! wc.cbClsExtra = 0; ! wc.cbWndExtra = 0; ! wc.hInstance = ::GetModuleHandle(NULL); ! wc.hIcon = LoadIcon(wc.hInstance, MAKEINTRESOURCE(RES_APP_ICON)); ! wc.hCursor = LoadCursor(0, IDC_ARROW); ! wc.hbrBackground = (HBRUSH)(COLOR_BTNFACE + 1); ! wc.lpszMenuName = window_class; ! wc.lpszClassName = window_class; ! RegisterClassW(&wc); ! HWND root_window = ::CreateWindowExW( WS_EX_WINDOWEDGE | WS_EX_DLGMODALFRAME | WS_EX_COMPOSITED, ! window_class, L"Adobe Begin", ! WS_OVERLAPPED | WS_CAPTION | WS_SYSMENU, ! 10, 10, 640, 100, NULL, ::CreateMenu(), ! ::GetModuleHandle(NULL), ! NULL); ! if (root_window == NULL) throw std::runtime_error("Could not open main window"); ! ::ShowWindow(root_window, SW_NORMAL); ! ::DragAcceptFiles(root_window, TRUE); ! ::SetWindowLongPtrA(root_window, GWLP_USERDATA, hackery::cast<LONG>(app)); ! // setup the menu system ! HMENU menu_bar(::GetMenu(root_window)); ! HMENU app_menu(::CreatePopupMenu()); ! HMENU view_options_menu(::CreatePopupMenu()); ! HMENU localization_menu(::CreatePopupMenu()); ! ::AppendMenu(app_menu, MF_STRING, ADOBE_ABOUT, _T("&About Adobe Begin")); ! ::AppendMenu(app_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(app_menu, MF_STRING, ADOBE_QUIT, _T("&Quit Adobe Begin")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_REFRESH_VIEW, _T("&Refresh View")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_REFRESH_SHEET, _T("R&efresh Sheet")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_NORMAL_DIALOG_SIZE, _T("&Normal Dialog Size")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SMALL_DIALOG_SIZE, _T("&Small Dialog Size")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_MINI_DIALOG_SIZE, _T("&Mini Dialog Size")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SHOW_WIDGET_FRAMES, _T("&Show Widget Frames")); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_CLEAR_WIDGET_FRAMES, _T("&Clear Widget Frames")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_SERIALIZE_WIDGETS, _T("&Serialize Widgets")); ! ::AppendMenu(view_options_menu, MF_SEPARATOR, 0, NULL); ! ::AppendMenu(view_options_menu, MF_STRING, ADOBE_RUN_MODAL, _T("&Run Modal")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_ENUS, _T("&Standard English (en-us)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_DEDE, _T("&German (de-de)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_JAJP, _T("&Japanese (ja-jp)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_KOKR, _T("&Korean (ko-kr)")); ! ::AppendMenu(localization_menu, MF_STRING, ADOBE_LOCALIZATION_PGPG, _T("&Pig Latin (pg-pg)")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(app_menu), _T("&Adobe Begin")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(view_options_menu), _T("&View Options")); ! ::AppendMenu(menu_bar, MF_POPUP, hackery::cast<UINT_PTR>(localization_menu), _T("&Localization")); ! ::DrawMenuBar(root_window); ! // set root in display ! adobe::get_main_display().set_root(root_window); } *************** *** 334,358 **** typedef std::vector<char> buffer_t; ! // we know any utf8 encoded character can't be more than 6 bytes, ! // so we just allocate an extra-large buffer to begin with instead ! // of calling WideCharToMultiByte twice. ! std::size_t wide_string_length(std::wcslen(wide_string)); ! std::size_t buffer_size(wide_string_length * 6); ! buffer_t buffer(buffer_size + 1); ! // // Convert characters. // ! int result_size(WideCharToMultiByte(CP_UTF8, 0, wide_string, static_cast<int>(wide_string_length), ! &buffer[0], static_cast<int>(buffer_size), 0, 0)); ! if (result_size == 0) ! return false; ! result.assign(std::string(&buffer[0], &buffer[result_size])); ! return true; } } // namespace hackery --- 334,358 ---- typedef std::vector<char> buffer_t; ! // we know any utf8 encoded character can't be more than 6 bytes, ! // so we just allocate an extra-large buffer to begin with instead ! // of calling WideCharToMultiByte twice. ! std::size_t wide_string_length(std::wcslen(wide_string)); ! std::size_t buffer_size(wide_string_length * 6); ! buffer_t buffer(buffer_size + 1); ! // // Convert characters. // ! int result_size(WideCharToMultiByte(CP_UTF8, 0, wide_string, static_cast<int>(wide_string_length), ! &buffer[0], static_cast<int>(buffer_size), 0, 0)); ! if (result_size == 0) ! return false; ! result.assign(std::string(&buffer[0], &buffer[result_size])); ! return true; } } // namespace hackery *************** *** 362,423 **** bool os_initialize( application_t* app ) { ! // ! // We only need to set the resource path on Windows. There are no ! // system events to install handlers for, etc. We say that the ! // resource path is the folder with the executable inside. ! // ! LPWSTR *szArglist; ! int nArgs; ! szArglist = CommandLineToArgvW(GetCommandLineW(), &nArgs); ! if( NULL == szArglist ) ! throw std::runtime_error("CommandLineToArgvW failed"); ! std::string directory_string; ! if (!hackery::LPCWSTR_to_string(szArglist[0], directory_string)) ! throw std::runtime_error("Path character conversion failed."); ! std::string file1; ! if (nArgs >= 2 && !hackery::LPCWSTR_to_string(szArglist[1], file1)) ! throw std::runtime_error("Path character conversion failed."); ! std::string file2; ! if (nArgs >= 3 && !hackery::LPCWSTR_to_string(szArglist[2], file2)) ! throw std::runtime_error("Path character conversion failed."); ! clip_quotes(directory_string); ! // ! // Now we need to get a directory from the command line name. ! // ! boost::filesystem::path directory( directory_string, boost::filesystem::native ); ! // ! // Tell the application... ! // ! app->set_resource_directory( directory.branch_path() ); ! setup_main_window( app ); ! if (!file1.empty()) ! { ! clip_quotes(file1); ! open_document(app, file1); ! } ! if (!file2.empty()) ! { ! clip_quotes(file2); ! open_document(app, file2); ! } ! LocalFree(szArglist); ! return true; } --- 362,423 ---- bool os_initialize( application_t* app ) { ! // ! // We only need to set the resource path on Windows. There are no ! // system events to install handlers for, etc. We say that the ! // resource path is the folder with the executable inside. ! // ! LPWSTR *szArglist; ! int nArgs; ! szArglist = CommandLineToArgvW(GetCommandLineW(), &nArgs); ! if( NULL == szArglist ) ! throw std::runtime_error("CommandLineToArgvW failed"); ! std::string directory_string; ! if (!hackery::LPCWSTR_to_string(szArglist[0], directory_string)) ! throw std::runtime_error("Path character conversion failed."); ! std::string file1; ! if (nArgs >= 2 && !hackery::LPCWSTR_to_string(szArglist[1], file1)) ! throw std::runtime_error("Path character conversion failed."); ! std::string file2; ! if (nArgs >= 3 && !hackery::LPCWSTR_to_string(szArglist[2], file2)) ! throw std::runtime_error("Path character conversion failed."); ! clip_quotes(directory_string); ! // ! // Now we need to get a directory from the command line name. ! // ! boost::filesystem::path directory( directory_string, boost::filesystem::native ); ! // ! // Tell the application... ! // ! app->set_resource_directory( directory.branch_path() ); ! setup_main_window( app ); ! if (!file1.empty()) ! { ! clip_quotes(file1); ! open_document(app, file1); ! } ! if (!file2.empty()) ! { ! clip_quotes(file2); ! open_document(app, file2); ! } ! LocalFree(szArglist); ! return true; } *************** *** 426,453 **** void os_mainloop() { ! // ! // This is just the standard Win32 message pump. ! // ! MSG msg; ! while ( GetMessage( &msg, 0, 0, 0 ) ) ! { ! try{ ! // ! // Push every message through the event_dispatcher, in case it is a keyboard ! // modifier. ! // ! event_dispatcher::keyboard(msg.message, msg.wParam); ! // ! // We always pass every message though to the application anyway. ! // ! TranslateMessage( &msg ); ! DispatchMessage( &msg ); ! } ! catch ( ... ) ! { ! adobe::report_exception(); ! } ! } } --- 426,453 ---- void os_mainloop() { ! // ! // This is just the standard Win32 message pump. ! // ! MSG msg; ! while ( GetMessage( &msg, 0, 0, 0 ) ) ! { ! try{ ! // ! // Push every message through the event_dispatcher, in case it is a keyboard ! // modifier. ! // ! event_dispatcher::keyboard(msg.message, msg.wParam); ! // ! // We always pass every message though to the application anyway. ! // ! TranslateMessage( &msg ); ! DispatchMessage( &msg ); ! } ! catch ( ... ) ! { ! adobe::report_exception(); ! } ! } } *************** *** 456,463 **** void os_end_mainloop() { ! // ! // This is just the standard Win32 quit message. ! // ! ::PostQuitMessage(0); } --- 456,463 ---- void os_end_mainloop() { ! // ! // This is just the standard Win32 quit message. ! // ! ::PostQuitMessage(0); } *************** *** 470,485 **** int __stdcall WinMain( HINSTANCE hInst, HINSTANCE hInstPrev, LPSTR lpCmdLine, int nCmdShow ) { ! try ! { ! adobe::application_t* theApp = adobe::application_t::getInstance(); ! if( theApp ) theApp->run(); ! } ! catch( ... ) ! { ! adobe::report_exception(); ! } ! return 0; } --- 470,485 ---- int __stdcall WinMain( HINSTANCE hInst, HINSTANCE hInstPrev, LPSTR lpCmdLine, int nCmdShow ) { ! try ! { ! adobe::application_t* theApp = adobe::application_t::getInstance(); ! if( theApp ) theApp->run(); ! } ! catch( ... ) ! { ! adobe::report_exception(); ! } ! return 0; } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:23
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/win32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets/headers/win32 Modified Files: event_dispatcher.hpp metrics.hpp ui_core_implementation.hpp wincast.hpp Log Message: asl 1.0.13 Index: event_dispatcher.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/win32/event_dispatcher.hpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** event_dispatcher.hpp 24 Jan 2006 19:38:47 -0000 1.1 --- event_dispatcher.hpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 47,121 **** class event_dispatcher { ! typedef std::map<int, control_t*> control_map_t; ! control_map_t control_map_m; ///< Mapping Child ID -> control_t* ! int current_id_m; ///< Child ID to next issue ! // ! /// This private constructor maintains the singleton nature of ! /// this class. ! // ! event_dispatcher(); ! friend class reference; public: ! // ! /// This reference class contains a reference to the event_dispatcher, ! /// and should be used by controls to subscribe and unsubscribe -- all ! /// controls should have one of these as a member variable. ! // ! class reference ! { ! int child_id_m; ///< The child ID for the owning control_t. ! public: ! // ! /// This constructor initializes all values to zero, and acquires a ! /// reference to the event_dispatcher. ! // ! reference(); ! // ! /// Unsubscribe any control which subscribed to the event_dispatcher ! /// and release the reference to the event_dispatcher. ! // ! ~reference(); ! // ! /// Subscribe the given control_t to the event_dispatcher. The returned ! /// value should be used as the child Id for the window which the given ! /// control will create. ! /// ! /// \param control the control to subscribe to events. ! /// \return the child id for the control to use. ! // ! HMENU subscribe(control_t* control); ! // ! /// Return the child ID. ! /// ! /// \return the child id to use for windows belonging to the subscribed ! /// control, or NULL if no control has subscribed through this ! /// reference. ! // ! HMENU child_id() const; ! }; ! // ! /// Dispatch an event through to the control which needs to process it. ! /// ! /// \param message The Windows message type. ! /// \param wParam The pointer parameter of the message. ! /// \param lParam the long parameter of the message. ! /// \param handled this reference bool is set to true if the message ! /// was dispatched to a child, or to false if no child ! /// could be found. ! /// \return the result of the event. ! // ! static LRESULT event(UINT message, WPARAM wParam, LPARAM lParam, bool& handled); ! // ! /// Examine the given keyboard message and send any required modifier events ! /// to controls. ! /// ! /// \param message The Windows message type. ! /// \param wParam The WPARAM value from the Windows message. ! // ! static void keyboard(UINT message, WPARAM wParam); }; /****************************************************************************************************/ ! } --- 47,121 ---- class event_dispatcher { ! typedef std::map<int, control_t*> control_map_t; ! control_map_t control_map_m; ///< Mapping Child ID -> control_t* ! int current_id_m; ///< Child ID to next issue ! // ! /// This private constructor maintains the singleton nature of ! /// this class. ! // ! event_dispatcher(); ! friend class reference; public: ! // ! /// This reference class contains a reference to the event_dispatcher, ! /// and should be used by controls to subscribe and unsubscribe -- all ! /// controls should have one of these as a member variable. ! // ! class reference ! { ! int child_id_m; ///< The child ID for the owning control_t. ! public: ! // ! /// This constructor initializes all values to zero, and acquires a ! /// reference to the event_dispatcher. ! // ! reference(); ! // ! /// Unsubscribe any control which subscribed to the event_dispatcher ! /// and release the reference to the event_dispatcher. ! // ! ~reference(); ! // ! /// Subscribe the given control_t to the event_dispatcher. The returned ! /// value should be used as the child Id for the window which the given ! /// control will create. ! /// ! /// \param control the control to subscribe to events. ! /// \return the child id for the control to use. ! // ! HMENU subscribe(control_t* control); ! // ! /// Return the child ID. ! /// ! /// \return the child id to use for windows belonging to the subscribed ! /// control, or NULL if no control has subscribed through this ! /// reference. ! // ! HMENU child_id() const; ! }; ! // ! /// Dispatch an event through to the control which needs to process it. ! /// ! /// \param message The Windows message type. ! /// \param wParam The pointer parameter of the message. ! /// \param lParam the long parameter of the message. ! /// \param handled this reference bool is set to true if the message ! /// was dispatched to a child, or to false if no child ! /// could be found. ! /// \return the result of the event. ! // ! static LRESULT event(UINT message, WPARAM wParam, LPARAM lParam, bool& handled); ! // ! /// Examine the given keyboard message and send any required modifier events ! /// to controls. ! /// ! /// \param message The Windows message type. ! /// \param wParam The WPARAM value from the Windows message. ! // ! static void keyboard(UINT message, WPARAM wParam); }; /****************************************************************************************************/ ! } Index: wincast.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/win32/wincast.hpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** wincast.hpp 24 Jan 2006 19:38:47 -0000 1.1 --- wincast.hpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 25,49 **** inline T cast(U u) { ! // REVISIT (fbrereto) : This function circumvents an issue where MSVC won't allow for the casting ! // of a primitive of smaller type to one of larger type. Please use sparingly, ! // but when this type of cast must be made use this function so it can be ! // pulled out easily. ! #pragma warning ( push ) ! #pragma warning ( disable : 4311 ) // typecast pointer truncation from type to type ! #pragma warning ( disable : 4312 ) // typecast conversion from type to type of greater size ! #pragma warning ( disable : 4800 ) // conversion to true/false performance warning ! return (T)(u); ! #pragma warning ( pop ) } /****************************************************************************************************/ ! } // namespace hackery /****************************************************************************************************/ ! } // namespace --- 25,49 ---- inline T cast(U u) { ! // REVISIT (fbrereto) : This function circumvents an issue where MSVC won't allow for the casting ! // of a primitive of smaller type to one of larger type. Please use sparingly, ! // but when this type of cast must be made use this function so it can be ! // pulled out easily. ! #pragma warning ( push ) ! #pragma warning ( disable : 4311 ) // typecast pointer truncation from type to type ! #pragma warning ( disable : 4312 ) // typecast conversion from type to type of greater size ! #pragma warning ( disable : 4800 ) // conversion to true/false performance warning ! return (T)(u); ! #pragma warning ( pop ) } /****************************************************************************************************/ ! } // namespace hackery /****************************************************************************************************/ ! } // namespace Index: ui_core_implementation.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/win32/ui_core_implementation.hpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ui_core_implementation.hpp 2 Feb 2006 09:10:30 -0000 1.2 --- ui_core_implementation.hpp 3 Feb 2006 18:33:36 -0000 1.3 *************** *** 1,11 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ ! #ifndef ADOBE_UI_CORE_IMPLEMENTATION_HPP #define ADOBE_UI_CORE_IMPLEMENTATION_HPP [...1114 lines suppressed...] ! void signal_value_change(const implementation::slider_value_proc_t& proc); ! ! ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_FRIEND_DECLARATION(adobe::slider_t::implementation_t); ! virtual dictionary_t essentials() const; ! implementation::slider_value_proc_t value_proc_m; ! bool is_vertical_m; ! slider_style_t style_m; ! long num_tick_marks_m; }; *************** *** 630,634 **** ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::unit_edit_text_t::implementation_t); ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::slider_t::implementation_t); - ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::bevel_button_t::implementation_t); /****************************************************************************************************/ --- 597,600 ---- Index: metrics.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/win32/metrics.hpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** metrics.hpp 24 Jan 2006 19:38:47 -0000 1.1 --- metrics.hpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 50,173 **** class metrics_t { public: ! // ! /// Return a reference to the single instance of metrics_t. ! /// ! /// \return a reference to the single instance of metrics_t. ! // ! static metrics_t& get_instance(); ! // ! /// Get the correct font to use for the given widget. This font must ! /// be used for the font metrics to be correct. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_font a reference filled with the requested font. ! /// ! /// \return true if the font was returned successfully, false if ! /// the font could not be returned. ! // ! virtual bool get_font(int widget_type, LOGFONTW& out_font) const = 0; ! // ! /// Get the metrics for the font which should be used in the given widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_metrics a reference filled with the text metrics. ! /// ! /// \return true if the font metrics were returned successfully, false ! /// if the metrics could not be returned. ! // ! virtual bool get_font_metrics(int widget_type, TEXTMETRIC& out_metrics) const = 0; ! // ! /// Get the extents for the given text string, to be contained in the ! /// specified widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param text the string to return the extents for. ! /// \param out_extents a reference filled with the text extents. ! /// ! /// \return true if the text extents were returned successfully, false ! /// if the metrics could not be returned. ! // ! virtual bool get_text_extents(int widget_type, std::wstring text, RECT& out_extents) const = 0; ! // ! /// Get the specified measurement for the given widget when in the ! /// given state. ! /// ! /// \param widget_type the type of the widget. ! /// \param measurement the required measurement. ! /// \param out_val a reference filled with the requested value. ! /// ! /// \return true if the value was returned successfully, false ! /// if the value could not be found. ! // ! virtual bool get_integer(int widget_type, int measurement, int& out_val) const = 0; ! // ! /// Get the size of the specified widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param measurement the size to get: TS_MIN, TS_TRUE, or TS_DRAW. ! /// \param out_size a reference filled with the requested rectangle. ! /// ! /// \return true if the rectangle was returned successfully, false ! /// if the rectangle could not be found. ! // ! virtual bool get_size(int widget_type, THEMESIZE measurement, SIZE& out_size) const = 0; ! // ! /// Get the margins for the specified widget. Typically the margins ! /// describe space which must be added around the text rectangle for ! /// controls with a caption. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_margins a reference filled with the margins of the widget. ! /// ! /// \return true if the margins were returned successfully, false ! /// if the margins could not be found. ! // ! virtual bool get_margins(int widget_type, MARGINS& out_margins) const = 0; ! // ! /// Get the text margins for a button widget. This call is specific ! /// to a button widget, but is only available with Visual Styles on ! /// Windows XP (hence is grouped in with the other metrics functions ! /// of similar availability). ! /// ! /// \param widget_type the UXTheme type of button ! /// \param out_margins a rectangle containing the margins ! /// ! /// \return true if the margins were returned successfully, false ! /// if the margins could not be found. ! // ! virtual bool get_button_text_margins(int widget_type, RECT& out_margins) const = 0; ! // ! /// Return true if visual styles are currently in use, false if they ! /// are not being used. ! /// ! /// \return true if visual styles are in use, false otherwise. ! // ! virtual bool using_styles() const = 0; ! // ! /// Use the current style to draw the background of the parent control ! /// of the given window using the given DC. This function is useful for ! /// drawing the background of controls which appear on top of tab controls, ! /// or other places where the color isn't regulation. ! /// ! /// \param window the window to draw the parent background of. ! /// \param dc the DC to draw with. This DC does not have to be ! /// drawing onto the given window. ! // ! virtual void draw_parent_background(HWND window, HDC dc) = 0; ! // ! /// Before any of the other functions can be called, the theme data must be ! /// loaded from the window. This function should also be called any time the ! /// window recieves a WM_THEMECHANGED message. ! /// ! /// \param window the window to get the theme from. Note that it is not ! /// important which window is used, it does not have to ! /// be the same window every time. ! /// ! /// \return true if the theme was obtained from the window, false if the ! /// theme could not be obtained from the window. ! // ! virtual bool set_window(HWND window) = 0; ! virtual ~metrics_t() { } }; --- 50,173 ---- class metrics_t { public: ! // ! /// Return a reference to the single instance of metrics_t. ! /// ! /// \return a reference to the single instance of metrics_t. ! // ! static metrics_t& get_instance(); ! // ! /// Get the correct font to use for the given widget. This font must ! /// be used for the font metrics to be correct. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_font a reference filled with the requested font. ! /// ! /// \return true if the font was returned successfully, false if ! /// the font could not be returned. ! // ! virtual bool get_font(int widget_type, LOGFONTW& out_font) const = 0; ! // ! /// Get the metrics for the font which should be used in the given widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_metrics a reference filled with the text metrics. ! /// ! /// \return true if the font metrics were returned successfully, false ! /// if the metrics could not be returned. ! // ! virtual bool get_font_metrics(int widget_type, TEXTMETRIC& out_metrics) const = 0; ! // ! /// Get the extents for the given text string, to be contained in the ! /// specified widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param text the string to return the extents for. ! /// \param out_extents a reference filled with the text extents. ! /// ! /// \return true if the text extents were returned successfully, false ! /// if the metrics could not be returned. ! // ! virtual bool get_text_extents(int widget_type, std::wstring text, RECT& out_extents) const = 0; ! // ! /// Get the specified measurement for the given widget when in the ! /// given state. ! /// ! /// \param widget_type the type of the widget. ! /// \param measurement the required measurement. ! /// \param out_val a reference filled with the requested value. ! /// ! /// \return true if the value was returned successfully, false ! /// if the value could not be found. ! // ! virtual bool get_integer(int widget_type, int measurement, int& out_val) const = 0; ! // ! /// Get the size of the specified widget. ! /// ! /// \param widget_type the type of the widget. ! /// \param measurement the size to get: TS_MIN, TS_TRUE, or TS_DRAW. ! /// \param out_size a reference filled with the requested rectangle. ! /// ! /// \return true if the rectangle was returned successfully, false ! /// if the rectangle could not be found. ! // ! virtual bool get_size(int widget_type, THEMESIZE measurement, SIZE& out_size) const = 0; ! // ! /// Get the margins for the specified widget. Typically the margins ! /// describe space which must be added around the text rectangle for ! /// controls with a caption. ! /// ! /// \param widget_type the type of the widget. ! /// \param out_margins a reference filled with the margins of the widget. ! /// ! /// \return true if the margins were returned successfully, false ! /// if the margins could not be found. ! // ! virtual bool get_margins(int widget_type, MARGINS& out_margins) const = 0; ! // ! /// Get the text margins for a button widget. This call is specific ! /// to a button widget, but is only available with Visual Styles on ! /// Windows XP (hence is grouped in with the other metrics functions ! /// of similar availability). ! /// ! /// \param widget_type the UXTheme type of button ! /// \param out_margins a rectangle containing the margins ! /// ! /// \return true if the margins were returned successfully, false ! /// if the margins could not be found. ! // ! virtual bool get_button_text_margins(int widget_type, RECT& out_margins) const = 0; ! // ! /// Return true if visual styles are currently in use, false if they ! /// are not being used. ! /// ! /// \return true if visual styles are in use, false otherwise. ! // ! virtual bool using_styles() const = 0; ! // ! /// Use the current style to draw the background of the parent control ! /// of the given window using the given DC. This function is useful for ! /// drawing the background of controls which appear on top of tab controls, ! /// or other places where the color isn't regulation. ! /// ! /// \param window the window to draw the parent background of. ! /// \param dc the DC to draw with. This DC does not have to be ! /// drawing onto the given window. ! // ! virtual void draw_parent_background(HWND window, HDC dc) = 0; ! // ! /// Before any of the other functions can be called, the theme data must be ! /// loaded from the window. This function should also be called any time the ! /// window recieves a WM_THEMECHANGED message. ! /// ! /// \param window the window to get the theme from. Note that it is not ! /// important which window is used, it does not have to ! /// be the same window every time. ! /// ! /// \return true if the theme was obtained from the window, false if the ! /// theme could not be obtained from the window. ! // ! virtual bool set_window(HWND window) = 0; ! virtual ~metrics_t() { } }; |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:23
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/sources/fltk In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/begin/sources/fltk Modified Files: main.cpp Log Message: asl 1.0.13 Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/sources/fltk/main.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** main.cpp 7 Jul 2005 22:16:21 -0000 1.1 --- main.cpp 3 Feb 2006 18:33:38 -0000 1.2 *************** *** 1,7 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) */ --- 1,7 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) */ *************** *** 27,48 **** bool os_initialize(application_t* app) { ! // ! // This is example code currently. It makes no real effort ! // to locate the resources. ! // ! app->set_resource_directory("examples"); ! app->set_adam_file("examples/image_size.adm"); ! app->set_eve_file("examples/image_size.eve"); ! return true; } void os_mainloop() { ! fltk::run(); } void os_end_mainloop() { ! exit(0); } --- 27,48 ---- bool os_initialize(application_t* app) { ! // ! // This is example code currently. It makes no real effort ! // to locate the resources. ! // ! app->set_resource_directory("examples"); ! app->set_adam_file("examples/image_size.adm"); ! app->set_eve_file("examples/image_size.eve"); ! return true; } void os_mainloop() { ! fltk::run(); } void os_end_mainloop() { ! exit(0); } *************** *** 53,66 **** int main() { ! // try ! { ! adobe::application_t* app = adobe::application_t::getInstance(); ! if (app) app->run(); ! } ! /* catch(...) ! { ! adobe::report_exception(); ! }*/ ! return 0; } --- 53,66 ---- int main() { ! // try ! { ! adobe::application_t* app = adobe::application_t::getInstance(); ! if (app) app->run(); ! } ! /* catch(...) ! { ! adobe::report_exception(); ! }*/ ! return 0; } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:23
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources/structure Modified Files: indices.dox mainpage.dox news.dox preface.dox toc.dox Log Message: asl 1.0.13 Index: indices.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure/indices.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** indices.dox 7 Jul 2005 22:48:38 -0000 1.1 --- indices.dox 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,6 **** /*! \page asl_indices Indices ! - <a href="annotated.html">Annotated Class List</a> ! - <a href="classes.html">Class Index</a> ! - <a href="functions.html">Member Index</a> ! - <a href="files.html">File Index</a> */ --- 1,6 ---- /*! \page asl_indices Indices ! - <a href="annotated.html">Annotated Class List</a> ! - <a href="classes.html">Class Index</a> ! - <a href="functions.html">Member Index</a> ! - <a href="files.html">File Index</a> */ Index: preface.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure/preface.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** preface.dox 19 Mar 2005 00:16:42 -0000 1.1 --- preface.dox 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 18,24 **** \par This theme is recurrent throughout ASL and is reflected in many aspects, including: ! - The reliance on value semantics, rather than reference or pointer semantics, as the mechanism to control connections. ! - Stating the requirements of algorithms in terms of semantic concepts rather than interfaces. ! - Making connections explicit and using explicit data structure, notable in the lack of inheritance as a coupling mechanism. <i>It is a good start...</i> --- 18,24 ---- \par This theme is recurrent throughout ASL and is reflected in many aspects, including: ! - The reliance on value semantics, rather than reference or pointer semantics, as the mechanism to control connections. ! - Stating the requirements of algorithms in terms of semantic concepts rather than interfaces. ! - Making connections explicit and using explicit data structure, notable in the lack of inheritance as a coupling mechanism. <i>It is a good start...</i> *************** *** 66,80 **** \par I would be remiss without thanking a number of people for their efforts in putting together this library. Any ranking would be unfair, so I list them here in some kind of lexicographical order. ! - Boost - ASL relies heavily on the Boost libraries and freely borrows ideas and techniques pioneered by the many great Boost contributors. Feel free to borrow back. ! - Foster Brereton, who has been my wingman working on ASL and Eve before there was ASL. This release would not have happened without him. ! - Greg Gilley, my boss, who has provided shelter for the Software Technology Lab and the support necessary to make this happen. ! - Grant Munsey, who opened the doors at Adobe to open source. We hope you continue to get better. ! - Martin Newell, whose Boxes program sparked the idea that led to Eve and whose support gave me time to explore countless iterations of Adam. ! - The Photoshop team, especially Andrew Coven, Scott Byer, Joe Ault, and (ex-Photoshop member) Mark Hamburg. They have listened to me ramble incoherently for countless hours as I have struggled to form the ideas expressed here. ! - Bob Pierce, who authored each of the Adobe open source licenses. ! - Alex Stepanov who, more than anyone, has shaped how I think about software. Initially, through his work on the Standard Template Library. Now, as a personal friend and colleague he pushes me to learn more and to seek real problems and solutions. His constant pushing has transformed my code from a hack to less of a hack. It is a start. ! - Bjarne Stroustrup, the C++ Standards Committee, and the C++ community, who provided a language with which I can attempt to express my ideas. ! - Those that have taken the time to review and contribute to ASL including, Doug Ahmann, Bob Archer, Eric Berdahl, Florin Trofin, Tony Van Eerd, John Yen. ! - My wife, Tricia, for her loving support. \par --- 66,80 ---- \par I would be remiss without thanking a number of people for their efforts in putting together this library. Any ranking would be unfair, so I list them here in some kind of lexicographical order. ! - Boost - ASL relies heavily on the Boost libraries and freely borrows ideas and techniques pioneered by the many great Boost contributors. Feel free to borrow back. ! - Foster Brereton, who has been my wingman working on ASL and Eve before there was ASL. This release would not have happened without him. ! - Greg Gilley, my boss, who has provided shelter for the Software Technology Lab and the support necessary to make this happen. ! - Grant Munsey, who opened the doors at Adobe to open source. We hope you continue to get better. ! - Martin Newell, whose Boxes program sparked the idea that led to Eve and whose support gave me time to explore countless iterations of Adam. ! - The Photoshop team, especially Andrew Coven, Scott Byer, Joe Ault, and (ex-Photoshop member) Mark Hamburg. They have listened to me ramble incoherently for countless hours as I have struggled to form the ideas expressed here. ! - Bob Pierce, who authored each of the Adobe open source licenses. ! - Alex Stepanov who, more than anyone, has shaped how I think about software. Initially, through his work on the Standard Template Library. Now, as a personal friend and colleague he pushes me to learn more and to seek real problems and solutions. His constant pushing has transformed my code from a hack to less of a hack. It is a start. ! - Bjarne Stroustrup, the C++ Standards Committee, and the C++ community, who provided a language with which I can attempt to express my ideas. ! - Those that have taken the time to review and contribute to ASL including, Doug Ahmann, Bob Archer, Eric Berdahl, Florin Trofin, Tony Van Eerd, John Yen. ! - My wife, Tricia, for her loving support. \par Index: news.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure/news.dox,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** news.dox 24 Jan 2006 19:38:44 -0000 1.6 --- news.dox 3 Feb 2006 18:33:36 -0000 1.7 *************** *** 6,9 **** --- 6,20 ---- \page top_news Top News + \par February 02, 2006 - ASL 1.0.13 Released + Highlights of the 1.0.13 changes include: + - Added a <code>adobe::nearest_cast</code> by Mark Ruzon + - Added <a href="http://opensource.adobe.com/twiki/bin/view/AdobeSource/ModalDialogIntegrationKit"><code>handle_dialog</code></a>, a self-contained API used to manage a modal dialog instance + - <code>adobe/cmath.hpp</code> has been augmented to include support for C99/TR1 extensions + - Improvements to the function modeling engine (Adam) + - A complete rewrite of the widgets library for the Mac + - For more information and more changes see the \ref asl_release_notes + \par + Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. + \par January 16, 2006 - GIL Tutorial and Design Guide Released \ref asl_gil \ref GILTutorial "tutorial" and \ref GILDesignGuide "design guide" is now available. Thanks to Lubomir Bourdev and Hailin Jin for all the work. *************** *** 13,23 **** \par January 05, 2006 - ASL 1.0.12 Released Highlights of the 1.0.12 changes include: ! - The \ref asl_gil has been added. This library allows for writing generic imaging algorithms with performance comparable to hand-coding for a particular image type ! - Lubomir has been hard at work getting the GIL tutorial and design guide ready for release. We anticipate it within a couple weeks. ! - ASL now compiles against Boost 1.33.1 ! - IDE projects have been added for XCode 2.2 ! - Many improvements to Adobe Begin and Win32's ui_core ! - A significant overhaul of adobe::forest. ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 24,34 ---- \par January 05, 2006 - ASL 1.0.12 Released Highlights of the 1.0.12 changes include: ! - The \ref asl_gil has been added. This library allows for writing generic imaging algorithms with performance comparable to hand-coding for a particular image type ! - Lubomir has been hard at work getting the GIL tutorial and design guide ready for release. We anticipate it within a couple weeks. ! - ASL now compiles against Boost 1.33.1 ! - IDE projects have been added for XCode 2.2 ! - Many improvements to Adobe Begin and Win32's ui_core ! - A significant overhaul of adobe::forest. ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 38,46 **** \par December 01, 2005 - ASL 1.0.11 Released Highlights of the 1.0.11 changes include: ! - MSVC 8 IDE projects for ASL and Begin have been released to take advantage of the new IDE features ! - Many compiler compatibility fixes for MSVC and Darwin (GCC) ! - Project updates for compatibility with XCode 2.2 ! - Work in the Win32 ui_core to bring parity between it and the Mac implementation ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 49,57 ---- \par December 01, 2005 - ASL 1.0.11 Released Highlights of the 1.0.11 changes include: ! - MSVC 8 IDE projects for ASL and Begin have been released to take advantage of the new IDE features ! - Many compiler compatibility fixes for MSVC and Darwin (GCC) ! - Project updates for compatibility with XCode 2.2 ! - Work in the Win32 ui_core to bring parity between it and the Mac implementation ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 53,74 **** http://opensource.adobe.com/twiki/bin/view/AdobeSource \par November 03, 2005 - ASL 1.0.10 Released Highlights of the 1.0.10 changes include: ! - Updates for compatibility with the upcoming MSVC 8 (Visual Studio 2005) release ! - Updates for compatibility with the upcoming Boost 1.33.1 release ! - Localization support integrated into Adobe Begin with a sample language glossary ! - Support for creating polymorphic regular objects as an alternative to object oriented programming (adobe::regular_object) ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. - \page previous_news Previous News \par October 06, 2005 - ASL 1.0.9 Released Highlights of the 1.0.9 changes include: ! - Added adobe::sha1_t, adobe::sha224_t, adobe::sha256_t, adobe::sha384_t, and adobe::sha512_t ! - Added adobe::dancing_links, an implementation of Knuth's Dancing Links Algorithm ! - BBv2 now builds a double-clickable Adobe Begin on MacOS X and Win32 - no IDE needed! ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 64,85 ---- http://opensource.adobe.com/twiki/bin/view/AdobeSource + \page previous_news Previous News \par November 03, 2005 - ASL 1.0.10 Released Highlights of the 1.0.10 changes include: ! - Updates for compatibility with the upcoming MSVC 8 (Visual Studio 2005) release ! - Updates for compatibility with the upcoming Boost 1.33.1 release ! - Localization support integrated into Adobe Begin with a sample language glossary ! - Support for creating polymorphic regular objects as an alternative to object oriented programming (adobe::regular_object) ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. \par October 06, 2005 - ASL 1.0.9 Released Highlights of the 1.0.9 changes include: ! - Added adobe::sha1_t, adobe::sha224_t, adobe::sha256_t, adobe::sha384_t, and adobe::sha512_t ! - Added adobe::dancing_links, an implementation of Knuth's Dancing Links Algorithm ! - BBv2 now builds a double-clickable Adobe Begin on MacOS X and Win32 - no IDE needed! ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 76,85 **** \par September 01, 2005 - ASL 1.0.8 Released Highlights of the 1.0.8 changes include: ! - Updated ASL to use Boost 1.33.0 ! - 4x speed increase in the xstring engine, both in parsing and lookups ! - Rewrote enum_ops to follow its original intent ! - Releasing All-In-One scripts that download all ASL dependencies, perform the necessary setup, and build the libraries ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 87,96 ---- \par September 01, 2005 - ASL 1.0.8 Released Highlights of the 1.0.8 changes include: ! - Updated ASL to use Boost 1.33.0 ! - 4x speed increase in the xstring engine, both in parsing and lookups ! - Rewrote enum_ops to follow its original intent ! - Releasing All-In-One scripts that download all ASL dependencies, perform the necessary setup, and build the libraries ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 87,95 **** \par August 04, 2005 - ASL 1.0.7 Released Highlights of the 1.0.7 changes include: ! - Dynamic visibility (hide/show) support in eve layout engine ! - adobe::index_iterator, adobe::any_iterator, adobe::reverse_fullorder_cursor, and adobe::filter_fullorder_cursor ! - adobe::const_once_name_t replaces adobe::once_name_t. ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 98,106 ---- \par August 04, 2005 - ASL 1.0.7 Released Highlights of the 1.0.7 changes include: ! - Dynamic visibility (hide/show) support in eve layout engine ! - adobe::index_iterator, adobe::any_iterator, adobe::reverse_fullorder_cursor, and adobe::filter_fullorder_cursor ! - adobe::const_once_name_t replaces adobe::once_name_t. ! - Updated Boost patch file; please re-patch your Boost distribution ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 97,105 **** \par July 07, 2005 - ASL 1.0.6 Released Highlights of the 1.0.6 changes include: ! - MacTel (Mac OS X on Intel) support ! - Automated building of libraries for IDE-based projects using BBv2 ! - Added <code>\<adobe/numeric.hpp\></code>, beginning similar support for <code>\<numeric\></code> as we have for <code>\<algorithm\></code> ! - Separation of the <code>adobe_widgets</code> UI library from Adobe Begin ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 108,116 ---- \par July 07, 2005 - ASL 1.0.6 Released Highlights of the 1.0.6 changes include: ! - MacTel (Mac OS X on Intel) support ! - Automated building of libraries for IDE-based projects using BBv2 ! - Added <code>\<adobe/numeric.hpp\></code>, beginning similar support for <code>\<numeric\></code> as we have for <code>\<algorithm\></code> ! - Separation of the <code>adobe_widgets</code> UI library from Adobe Begin ! - For more information and more changes see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 107,113 **** \par June 03, 2005 - ASL 1.0.5 Released There were enough problems with the 1.0.4 release that a 1.0.5 release has been rolled. Among the changes: ! - Added adobe/test/xstr_test and adobe/test/md5, directories for testing those respective parts of ASL, which the Boost Build system was expecting ! - Added adobe/test/Jamfile.v2, without which none of the test binaries would have built via the Boost Build system ! - Much more - see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 118,124 ---- \par June 03, 2005 - ASL 1.0.5 Released There were enough problems with the 1.0.4 release that a 1.0.5 release has been rolled. Among the changes: ! - Added adobe/test/xstr_test and adobe/test/md5, directories for testing those respective parts of ASL, which the Boost Build system was expecting ! - Added adobe/test/Jamfile.v2, without which none of the test binaries would have built via the Boost Build system ! - Much more - see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 115,124 **** \par June 02, 2005 - ASL 1.0.4 Released The Adobe Source Libraries 1.0.4 release contains a lot of bug fixes and changes: ! - We now support fully automated builds and regression tests using Boost Build version 2 project files. ! - Windows builds now fully supported. ! - Win32 Adobe Begin now has the Editor palette, allowing you to explore various aspects of the dialog you are viewing ! - Added an Adam smoke test application for command-line validity testing of Adam sheets ! - ZUID: UUID-like identifiers that do not contain personal information in them (like MAC addresses) ! - Much more - see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. --- 126,135 ---- \par June 02, 2005 - ASL 1.0.4 Released The Adobe Source Libraries 1.0.4 release contains a lot of bug fixes and changes: ! - We now support fully automated builds and regression tests using Boost Build version 2 project files. ! - Windows builds now fully supported. ! - Win32 Adobe Begin now has the Editor palette, allowing you to explore various aspects of the dialog you are viewing ! - Added an Adam smoke test application for command-line validity testing of Adam sheets ! - ZUID: UUID-like identifiers that do not contain personal information in them (like MAC addresses) ! - Much more - see the \ref asl_release_notes \par Head over to the <a href="http://sourceforge.net/project/showfiles.php?group_id=132417&package_id=145420">download</a> section to grab it. *************** *** 137,143 **** \htmlonly <ul> ! <li><a href="http://sourceforge.net/export/rss2_projnews.php?group_id=132417"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> Latest news</li> ! <li><a href="http://sourceforge.net/export/rss2_projnews.php?group_id=132417&rss_fulltext=1"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> Latest news (with full text)</li> ! <li><a href="http://sourceforge.net/export/rss2_projfiles.php?group_id=132417"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> File releases</li> </ul> \endhtmlonly --- 148,154 ---- \htmlonly <ul> ! <li><a href="http://sourceforge.net/export/rss2_projnews.php?group_id=132417"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> Latest news</li> ! <li><a href="http://sourceforge.net/export/rss2_projnews.php?group_id=132417&rss_fulltext=1"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> Latest news (with full text)</li> ! <li><a href="http://sourceforge.net/export/rss2_projfiles.php?group_id=132417"><img src="http://images.sourceforge.net/images/xml.png" border="0" alt="RSS Feed Available" width="36" height="14" style="vertical-align: middle"></a> File releases</li> </ul> \endhtmlonly Index: toc.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure/toc.dox,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** toc.dox 6 Jan 2006 18:02:56 -0000 1.9 --- toc.dox 3 Feb 2006 18:33:36 -0000 1.10 *************** *** 3,98 **** \if opensource_website - General ! - \ref asl_overview ! - \ref asl_foreword \endif - Language References ! - \ref adam_reference ! - \ref eve_reference ! - \ref expression_reference - \ref asl_concepts ! - \ref stldoc_Assignable ! - \ref stldoc_BackInsertionSequence ! - \ref concept_convertible_to_bool ! - \ref concept_convertible_to_function ! - \ref concept_convertible_to_range ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_EqualityComparable ! - \ref stldoc_FrontInsertionSequence ! - \ref stldoc_LessThanComparable ! - \ref concept_regular_type ! - \ref stldoc_ReversibleContainer ! - \ref concept_transform_function - \ref asl_libraries ! - \ref adam_engine ! - \ref adamparser ! - \ref algorithm ! - \ref conversion ! - \ref enum_ops ! - \ref eve_engine ! - \ref eveparser ! - \ref asl_gil ! - \ref adobe_final ! - \ref forest_related ! - \ref adobe_functional ! - \ref adobe_iterator ! - \ref adobe_once ! - \ref regular_object_related ! - \ref adobe_sha ! - \ref adobe_string ! - \ref asl_thread_id ! - \ref asl_unicode ! - \ref asl_xstring ! - \ref widget_lib [Future] ! - \ref widget_reference ! \if opensource_website - \ref ui_core \endif ! - Functions ! - adobe::align_slices - Classes ! - adobe::array_t ! - adobe::array_t::back_insert_iterator ! - adobe::bad_cast ! - adobe::circular_queue ! - adobe::copy_on_write ! - adobe::counter_t ! - adobe::dancing_links ! - adobe::dictionary_t ! - adobe::empty_t ! - adobe::extents_t ! - adobe::extents_t::slice_t ! - adobe::extents_slices_t ! - adobe::line_position_t ! - adobe::md5_t ! - adobe::name_t ! - adobe::const_once_name_t ! - adobe::static_name_t ! - \ref adobe_sha ! - adobe::sha1_t ! - adobe::sha224_t ! - adobe::sha256_t ! - adobe::sha384_t ! - adobe::sha512_t ! - adobe::static_table ! - adobe::static_table_traits ! - adobe::stream_error_t ! - adobe::table_index ! - adobe::timer_t ! - adobe::value_t ! - adobe::value_t::transform ! - adobe::virtual_machine_t ! - adobe::virtual_machine_t::tracked_value_t ! - adobe::zuid_t - \ref asl_tutorials ! - General ! - \ref asl_tutorials_namespaces ! - \ref asl_tutorials_array_t ! - \ref asl_tutorials_dictionary_t ! - \ref asl_tutorials_eve ! - \ref asl_tutorials_forest ! - \ref asl_tutorials_value_t - Indices ! - <a href="annotated.html">Annotated Class List</a> ! - <a href="classes.html">Class Index</a> ! - <a href="functions.html">Member Index</a> ! - <a href="files.html">File Index</a> */ --- 3,99 ---- \if opensource_website - General ! - \ref asl_overview ! - \ref asl_foreword \endif - Language References ! - \ref adam_reference ! - \ref eve_reference ! - \ref expression_reference - \ref asl_concepts ! - \ref stldoc_Assignable ! - \ref stldoc_BackInsertionSequence ! - \ref concept_convertible_to_bool ! - \ref concept_convertible_to_function ! - \ref concept_convertible_to_range ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_EqualityComparable ! - \ref stldoc_FrontInsertionSequence ! - \ref stldoc_LessThanComparable ! - \ref concept_regular_type ! - \ref stldoc_ReversibleContainer ! - \ref concept_transform_function - \ref asl_libraries ! - \ref adam_engine ! - \ref adamparser ! - \ref algorithm ! - \ref conversion ! - \ref cmath ! - \ref enum_ops ! - \ref eve_engine ! - \ref eveparser ! - \ref asl_gil ! - \ref adobe_final ! - \ref forest_related ! - \ref adobe_functional ! - \ref adobe_iterator ! - \ref adobe_once ! - \ref regular_object_related ! - \ref adobe_sha ! - \ref adobe_string ! - \ref asl_thread_id ! - \ref asl_unicode ! - \ref asl_xstring ! - \ref widget_lib [Future] ! - \ref widget_reference ! - \ref ui_core ! - Functions ! - adobe::align_slices - Classes ! - adobe::array_t ! - adobe::array_t::back_insert_iterator ! - adobe::bad_cast ! - adobe::circular_queue ! - adobe::copy_on_write ! - adobe::counter_t ! - adobe::dancing_links ! - adobe::dictionary_t ! - adobe::empty_t ! - adobe::extents_t ! - adobe::extents_t::slice_t ! - adobe::extents_slices_t ! - adobe::line_position_t ! - adobe::md5_t ! - adobe::name_t ! - adobe::const_once_name_t ! - adobe::static_name_t ! - \ref adobe_sha ! - adobe::sha1_t ! - adobe::sha224_t ! - adobe::sha256_t ! - adobe::sha384_t ! - adobe::sha512_t ! - adobe::static_table ! - adobe::static_table_traits ! - adobe::stream_error_t ! - adobe::table_index ! - adobe::timer_t ! - adobe::value_t ! - adobe::value_t::transform ! - adobe::virtual_machine_t ! - adobe::virtual_machine_t::tracked_value_t ! - adobe::zuid_t - \ref asl_tutorials ! - General ! - \ref asl_tutorials_namespaces ! - \ref asl_tutorials_array_t ! - \ref asl_tutorials_dictionary_t ! - \ref asl_tutorials_eve ! - \ref asl_tutorials_forest ! - \ref asl_tutorials_value_t - Indices ! - <a href="annotated.html">Annotated Class List</a> ! - <a href="classes.html">Class Index</a> ! - <a href="functions.html">Member Index</a> ! - <a href="files.html">File Index</a> */ Index: mainpage.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/structure/mainpage.dox,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** mainpage.dox 2 Dec 2005 02:59:15 -0000 1.12 --- mainpage.dox 3 Feb 2006 18:33:36 -0000 1.13 *************** *** 20,42 **** <div align="center"> <form method=get action="http://search.yahoo.com/search"> ! <input type="hidden" name="fr" value="yscpb"/> ! <input type="hidden" name="vs" id="ysvs1" style="vertical-align: middle" value="opensource.adobe.com"/> ! <table align="center"> ! <tr> ! <td rowspan="2" valign="middle"> ! <a href="http://search.yahoo.com/"> ! <img src="http://us.i1.yimg.com/us.yimg.com/i/us/search/ysan/ysanlogo.gif" border="0" style="vertical-align: middle"/> ! </a> ! </td> ! <td> ! <input type="text" name="p" size="29"/> ! <input type="submit" value="Search"/> ! </td> ! <tr> ! <td> ! <font size="-2">Search opensource.adobe.com</font> ! </td> ! </tr> ! </table> </form> </div> --- 20,42 ---- <div align="center"> <form method=get action="http://search.yahoo.com/search"> ! <input type="hidden" name="fr" value="yscpb"/> ! <input type="hidden" name="vs" id="ysvs1" style="vertical-align: middle" value="opensource.adobe.com"/> ! <table align="center"> ! <tr> ! <td rowspan="2" valign="middle"> ! <a href="http://search.yahoo.com/"> ! <img src="http://us.i1.yimg.com/us.yimg.com/i/us/search/ysan/ysanlogo.gif" border="0" style="vertical-align: middle"/> ! </a> ! </td> ! <td> ! <input type="text" name="p" size="29"/> ! <input type="submit" value="Search"/> ! </td> ! <tr> ! <td> ! <font size="-2">Search opensource.adobe.com</font> ! </td> ! </tr> ! </table> </form> </div> |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:23
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/fltk In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets/sources/fltk Modified Files: display.cpp ui_core_implementation.cpp ui_overlay.cpp Added Files: os_utilities.cpp Log Message: asl 1.0.13 Index: display.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/fltk/display.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** display.cpp 24 Jan 2006 19:38:47 -0000 1.3 --- display.cpp 3 Feb 2006 18:33:37 -0000 1.4 *************** *** 1,7 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) */ --- 1,7 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) */ *************** *** 21,37 **** struct view_wrap { ! explicit view_wrap(fltk::Widget* ref) : ref_m(ref) {} ! fltk::Widget* ref_m; }; fltk::Widget* unwrap(adobe::display_t::position_t& position) { ! return (boost::any_cast<view_wrap>(position)).ref_m; } adobe::display_t::position_t wrap(fltk::Widget* view) { ! return adobe::display_t::position_t(view_wrap(view)); } --- 21,37 ---- struct view_wrap { ! explicit view_wrap(fltk::Widget* ref) : ref_m(ref) {} ! fltk::Widget* ref_m; }; fltk::Widget* unwrap(adobe::display_t::position_t& position) { ! return (boost::any_cast<view_wrap>(position)).ref_m; } adobe::display_t::position_t wrap(fltk::Widget* view) { ! return adobe::display_t::position_t(view_wrap(view)); } *************** *** 50,60 **** display_t& get_main_display() { ! static display_t display_s; ! return display_s; } struct display_t::implementation_t { ! std::vector<fltk::Widget*> roots_m; }; --- 50,60 ---- display_t& get_main_display() { ! static display_t display_s; ! return display_s; } struct display_t::implementation_t { ! std::vector<fltk::Widget*> roots_m; }; *************** *** 74,91 **** display_t::~display_t() { ! delete object_m; ! object_m = 0; } display_t::implementation_t& display_t::implementation() { ! return *object_m; } const display_t::implementation_t& display_t::implementation() const { ! return *object_m; } display_t::position_t display_t::root() { ! return display_t::position_t(root_token()); } void display_t::erase(position_t& position) {} --- 74,91 ---- display_t::~display_t() { ! delete object_m; ! object_m = 0; } display_t::implementation_t& display_t::implementation() { ! return *object_m; } const display_t::implementation_t& display_t::implementation() const { ! return *object_m; } display_t::position_t display_t::root() { ! return display_t::position_t(root_token()); } void display_t::erase(position_t& position) {} *************** *** 94,98 **** display_t::position_t display_t::insert(position_t& parent, DisplayElement& element) { ! return insert(parent, adobe::view_for_element<fltk::Widget*>(element)); } --- 94,98 ---- display_t::position_t display_t::insert(position_t& parent, DisplayElement& element) { ! return insert(parent, adobe::view_for_element<fltk::Widget*>(element)); } *************** *** 102,113 **** display_t::position_t display_t::insert<fltk::Widget*>(position_t& parent, fltk::Widget*& element) { ! if (parent.type() == typeid(view_wrap)) ! { ! fltk::Group* parent_view(static_cast<fltk::Group*>(unwrap(parent))); ! parent_view->add(element); ! } ! else if (parent.type() == typeid(root_token)) ! object_m->roots_m.push_back(element); ! return wrap(element); } --- 102,113 ---- display_t::position_t display_t::insert<fltk::Widget*>(position_t& parent, fltk::Widget*& element) { ! if (parent.type() == typeid(view_wrap)) ! { ! fltk::Group* parent_view(static_cast<fltk::Group*>(unwrap(parent))); ! parent_view->add(element); ! } ! else if (parent.type() == typeid(root_token)) ! object_m->roots_m.push_back(element); ! return wrap(element); } Index: ui_overlay.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/fltk/ui_overlay.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ui_overlay.cpp 7 Nov 2005 18:08:58 -0000 1.2 --- ui_overlay.cpp 3 Feb 2006 18:33:37 -0000 1.3 *************** *** 1,9 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) ! This is just a stub for an actual ui_overlay. */ --- 1,9 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! (see accompanying file LICENSE_1_0_0.txt or a copy at ! http://opensource.adobe.com/licenses.html) ! This is just a stub for an actual ui_overlay. */ *************** *** 22,34 **** struct ui_overlay_t::implementation_t { ! int dummy; }; ui_overlay_t::ui_overlay_t() : ! object_m(new implementation_t()) { } ui_overlay_t::~ui_overlay_t() { ! delete object_m; } --- 22,34 ---- struct ui_overlay_t::implementation_t { ! int dummy; }; ui_overlay_t::ui_overlay_t() : ! object_m(new implementation_t()) { } ui_overlay_t::~ui_overlay_t() { ! delete object_m; } *************** *** 50,58 **** ui_overlay_t::implementation_t& ui_overlay_t::implementation() { ! return *object_m; } const ui_overlay_t::implementation_t& ui_overlay_t::implementation() const { ! return *object_m; } --- 50,58 ---- ui_overlay_t::implementation_t& ui_overlay_t::implementation() { ! return *object_m; } const ui_overlay_t::implementation_t& ui_overlay_t::implementation() const { ! return *object_m; } --- NEW FILE: os_utilities.cpp --- /* Copyright 2005-2006 Adobe Systems Incorporated Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ // This file intentionally left blank /****************************************************************************************************/ Index: ui_core_implementation.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/fltk/ui_core_implementation.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** ui_core_implementation.cpp 24 Jan 2006 08:42:18 -0000 1.5 --- ui_core_implementation.cpp 3 Feb 2006 18:33:37 -0000 1.6 *************** *** 1,8 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License ! See accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html */ --- 1,8 ---- /* [...4031 lines suppressed...] } ! ADOBE_INSERT_BOILERPLATE_SPECIALIZATION(window_t); // --- 2094,2108 ---- template<> display_t::position_t insert<unit_edit_text_t>(display_t& display, ! display_t::position_t& parent, unit_edit_text_t& element) { ! fltk::Widget* edit(adobe::view_for_element<fltk::Widget*>(element)); ! fltk::Widget* popup(adobe::view_for_element<fltk::Widget*>(element.implementation().get_popup())); ! display_t::position_t result = display.insert<fltk::Widget*>(parent, edit); ! if (popup) display.insert<fltk::Widget*>(parent, popup); ! return result; } ! ADOBE_INSERT_BOILERPLATE_SPECIALIZATION(window_t); // |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:23
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/eve_smoke In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/eve_smoke Modified Files: default.eve main.cpp Log Message: asl 1.0.13 Index: default.eve =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/eve_smoke/default.eve,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** default.eve 30 Mar 2005 22:34:35 -0000 1.1 --- default.eve 3 Feb 2006 18:33:39 -0000 1.2 *************** *** 1,11 **** dialog() { ! row() ! { ! button (name: "Hello"); ! } ! column() ! { ! button (name: "world!"); ! } } --- 1,11 ---- dialog() { ! row() ! { ! button (name: "Hello"); ! } ! column() ! { ! button (name: "world!"); ! } } Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/eve_smoke/main.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** main.cpp 24 Jan 2006 19:38:51 -0000 1.4 --- main.cpp 3 Feb 2006 18:33:39 -0000 1.5 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas and Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas and Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 39,49 **** /// \return an any containing the created widget. // ! adobe::eve_callback_suite_t::position_t assemble( adobe::name_t name, ! const adobe::dictionary_t& parameters) { ! std::cout << "Create: " << name.get() << std::endl; ! std::cout << parameters << std::endl; ! return adobe::eve_callback_suite_t::position_t(); } --- 39,49 ---- /// \return an any containing the created widget. // ! adobe::eve_callback_suite_t::position_t assemble( adobe::name_t name, ! const adobe::dictionary_t& parameters) { ! std::cout << "Create: " << name.get() << std::endl; ! std::cout << parameters << std::endl; ! return adobe::eve_callback_suite_t::position_t(); } *************** *** 59,85 **** void testParse( boost::filesystem::path& fileName ) { ! // ! // Open our input stream. ! // ! boost::filesystem::ifstream stream( fileName ); ! if (!stream.is_open()) ! { ! std::stringstream err; ! err << "Could not open file: " << fileName.native_file_string(); ! throw std::runtime_error(err.str()); ! } ! // ! // Call the Eve parser. ! // adobe::basic_sheet_t layout_sheet; adobe::virtual_machine_t evaluator; ! adobe::parse(stream, adobe::line_position_t(fileName.native_file_string().c_str()), ! adobe::eve_callback_suite_t::position_t(), adobe::bind_layout(boost::bind(&assemble, _2, _3), layout_sheet, evaluator)); } --- 59,85 ---- void testParse( boost::filesystem::path& fileName ) { ! // ! // Open our input stream. ! // ! boost::filesystem::ifstream stream( fileName ); ! if (!stream.is_open()) ! { ! std::stringstream err; ! err << "Could not open file: " << fileName.native_file_string(); ! throw std::runtime_error(err.str()); ! } ! // ! // Call the Eve parser. ! // adobe::basic_sheet_t layout_sheet; adobe::virtual_machine_t evaluator; ! adobe::parse(stream, adobe::line_position_t(fileName.native_file_string().c_str()), ! adobe::eve_callback_suite_t::position_t(), adobe::bind_layout(boost::bind(&assemble, _2, _3), layout_sheet, evaluator)); } *************** *** 103,138 **** int main( int argc, char* argv[] ) { ! bool success(true); ! // ! // Try to open the filename given on the command line, otherwise ! // try to open "default.eve". ! // ! try ! { ! boost::filesystem::path file_path("default.eve"); ! if( argc > 1 ) file_path = boost::filesystem::path(argv[1], boost::filesystem::native); ! // ! // Call our testParse function with the selected filename. ! // ! testParse( file_path ); ! } ! catch( const std::exception& error ) ! { ! // ! // Oops, something didn't work out. ! // ! std::cerr << "Exception: " << error.what() << std::endl; ! } ! catch( ... ) ! { ! std::cerr << "Unknown exception" << std::endl; ! } ! return success ? 0 : 1; } --- 103,138 ---- int main( int argc, char* argv[] ) { ! bool success(true); ! // ! // Try to open the filename given on the command line, otherwise ! // try to open "default.eve". ! // ! try ! { ! boost::filesystem::path file_path("default.eve"); ! if( argc > 1 ) file_path = boost::filesystem::path(argv[1], boost::filesystem::native); ! // ! // Call our testParse function with the selected filename. ! // ! testParse( file_path ); ! } ! catch( const std::exception& error ) ! { ! // ! // Oops, something didn't work out. ! // ! std::cerr << "Exception: " << error.what() << std::endl; ! } ! catch( ... ) ! { ! std::cerr << "Unknown exception" << std::endl; ! } ! return success ? 0 : 1; } |
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/win32 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets/sources/win32 Modified Files: display.cpp event_dispatcher.cpp metrics.cpp ui_core_implementation.cpp ui_overlay.cpp Added Files: os_utilities.cpp Log Message: asl 1.0.13 Index: ui_overlay.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/win32/ui_overlay.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ui_overlay.cpp 24 Jan 2006 19:38:49 -0000 1.1 --- ui_overlay.cpp 3 Feb 2006 18:33:37 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 27,37 **** struct overlay_data_t { ! adobe::point_2d_t origin_m; ! adobe::extents_t extents_m; }; ! typedef adobe::forest<overlay_data_t> overlay_forest_t; ! typedef POINT coord_t; ! typedef std::vector<coord_t> coord_set_t; /****************************************************************************************************/ --- 27,37 ---- struct overlay_data_t { ! adobe::point_2d_t origin_m; ! adobe::extents_t extents_m; }; ! typedef adobe::forest<overlay_data_t> overlay_forest_t; ! typedef POINT coord_t; ! typedef std::vector<coord_t> coord_set_t; /****************************************************************************************************/ *************** *** 39,43 **** overlay_forest_t::iterator unwrap(adobe::ui_overlay_t::position_t& position) { ! return boost::any_cast<overlay_forest_t::iterator>(position); } --- 39,43 ---- overlay_forest_t::iterator unwrap(adobe::ui_overlay_t::position_t& position) { ! return boost::any_cast<overlay_forest_t::iterator>(position); } *************** *** 46,50 **** adobe::ui_overlay_t::position_t wrap(overlay_forest_t::iterator view) { ! return adobe::ui_overlay_t::position_t(view); } --- 46,50 ---- adobe::ui_overlay_t::position_t wrap(overlay_forest_t::iterator view) { ! return adobe::ui_overlay_t::position_t(view); } *************** *** 53,75 **** RECT get_window_client_offset_rect(HWND window) { ! assert(window); ! RECT window_rect; ! RECT client_rect; ! ::GetWindowRect(window, &window_rect); ! ::GetClientRect(window, &client_rect); ! ::ClientToScreen(window, (LPPOINT) &client_rect.left); ! ::ClientToScreen(window, (LPPOINT) &client_rect.right); ! RECT result; ! result.left = std::abs(window_rect.left - client_rect.left); ! result.top = std::abs(window_rect.top - client_rect.top); ! result.right = std::abs(window_rect.right - client_rect.right); ! result.bottom = std::abs(window_rect.bottom - client_rect.bottom); ! return result; } --- 53,75 ---- RECT get_window_client_offset_rect(HWND window) { ! assert(window); ! RECT window_rect; ! RECT client_rect; ! ::GetWindowRect(window, &window_rect); ! ::GetClientRect(window, &client_rect); ! ::ClientToScreen(window, (LPPOINT) &client_rect.left); ! ::ClientToScreen(window, (LPPOINT) &client_rect.right); ! RECT result; ! result.left = std::abs(window_rect.left - client_rect.left); ! result.top = std::abs(window_rect.top - client_rect.top); ! result.right = std::abs(window_rect.right - client_rect.right); ! result.bottom = std::abs(window_rect.bottom - client_rect.bottom); ! return result; } *************** *** 78,86 **** void draw_line_path(HDC context, coord_set_t& points) { ! if (points.size() < 2) return; ! ::Polyline(context, &points[0], static_cast<int>(points.size())); ! points.erase(points.begin(), points.end()); } --- 78,86 ---- void draw_line_path(HDC context, coord_set_t& points) { ! if (points.size() < 2) return; ! ::Polyline(context, &points[0], static_cast<int>(points.size())); ! points.erase(points.begin(), points.end()); } *************** *** 97,150 **** struct ui_overlay_t::implementation_t { ! implementation_t(); ! ~implementation_t(); ! struct draw_element_t ! { ! enum element_type ! { ! element_type_top_left, ! element_type_top_right, ! element_type_bottom_left, ! element_type_bottom_right, ! element_type_horizontal_poi, ! element_type_vertical_poi, ! element_type_count // always be last ! }; ! draw_element_t(element_type type, const RECT& rect, const COLORREF& color) : ! type_m(type), rect_m(rect), color_m(color) ! { } ! draw_element_t(const draw_element_t& rhs) : ! type_m(rhs.type_m), rect_m(rhs.rect_m), color_m(rhs.color_m) ! { } ! element_type type_m; ! RECT rect_m; ! COLORREF color_m; ! }; ! typedef std::vector<draw_element_t> draw_element_set_t; ! position_t root(HWND& element); ! position_t insert(position_t parent); ! void place(position_t node, const point_2d_t& origin, const extents_t& extents); ! void framing(bool do_framing); ! overlay_data_t flatten_overlay_data(overlay_forest_t::iterator iter); ! void tick_extents(const overlay_data_t& overlay_data, HWND main_window, draw_element_set_t& set); ! void draw_tick(HDC context, const draw_element_set_t::value_type& element); ! HWND overlay_m; ! HWND source_m; ! bool framing_m; ! overlay_forest_t tree_m; }; --- 97,150 ---- struct ui_overlay_t::implementation_t { ! implementation_t(); ! ~implementation_t(); ! struct draw_element_t ! { ! enum element_type ! { ! element_type_top_left, ! element_type_top_right, ! element_type_bottom_left, ! element_type_bottom_right, ! element_type_horizontal_poi, ! element_type_vertical_poi, ! element_type_count // always be last ! }; ! draw_element_t(element_type type, const RECT& rect, const COLORREF& color) : ! type_m(type), rect_m(rect), color_m(color) ! { } ! draw_element_t(const draw_element_t& rhs) : ! type_m(rhs.type_m), rect_m(rhs.rect_m), color_m(rhs.color_m) ! { } ! element_type type_m; ! RECT rect_m; ! COLORREF color_m; ! }; ! typedef std::vector<draw_element_t> draw_element_set_t; ! position_t root(HWND& element); ! position_t insert(position_t parent); ! void place(position_t node, const point_2d_t& origin, const extents_t& extents); ! void framing(bool do_framing); ! overlay_data_t flatten_overlay_data(overlay_forest_t::iterator iter); ! void tick_extents(const overlay_data_t& overlay_data, HWND main_window, draw_element_set_t& set); ! void draw_tick(HDC context, const draw_element_set_t::value_type& element); ! HWND overlay_m; ! HWND source_m; ! bool framing_m; ! overlay_forest_t tree_m; }; *************** *** 152,156 **** ui_overlay_t::ui_overlay_t() : ! object_m(new implementation_t()) { } --- 152,156 ---- ui_overlay_t::ui_overlay_t() : ! object_m(new implementation_t()) { } *************** *** 184,188 **** #if 0 ! #pragma mark - #endif --- 184,188 ---- #if 0 ! #pragma mark - #endif *************** *** 190,196 **** ui_overlay_t::implementation_t::implementation_t() : ! overlay_m(0), ! source_m(0), ! framing_m(false) { } --- 190,196 ---- ui_overlay_t::implementation_t::implementation_t() : ! overlay_m(0), ! source_m(0), ! framing_m(false) { } *************** *** 199,205 **** ui_overlay_t::implementation_t::~implementation_t() { ! if (overlay_m) ::DestroyWindow(overlay_m); ! overlay_m = 0; } --- 199,205 ---- ui_overlay_t::implementation_t::~implementation_t() { ! if (overlay_m) ::DestroyWindow(overlay_m); ! overlay_m = 0; } *************** *** 208,216 **** ui_overlay_t::position_t ui_overlay_t::implementation_t::root(HWND& element) { ! assert(element); ! source_m = element; ! return wrap(tree_m.insert(tree_m.begin(), overlay_data_t())); } --- 208,216 ---- ui_overlay_t::position_t ui_overlay_t::implementation_t::root(HWND& element) { ! assert(element); ! source_m = element; ! return wrap(tree_m.insert(tree_m.begin(), overlay_data_t())); } *************** *** 219,227 **** ui_overlay_t::position_t ui_overlay_t::implementation_t::insert(position_t parent) { ! overlay_forest_t::iterator position(unwrap(parent)); position.edge() = adobe::forest_trailing_edge; ! return wrap(tree_m.insert(position, overlay_data_t())); } --- 219,227 ---- ui_overlay_t::position_t ui_overlay_t::implementation_t::insert(position_t parent) { ! overlay_forest_t::iterator position(unwrap(parent)); position.edge() = adobe::forest_trailing_edge; ! return wrap(tree_m.insert(position, overlay_data_t())); } *************** *** 230,237 **** void ui_overlay_t::implementation_t::place(position_t node, const point_2d_t& origin, const extents_t& extents) { ! overlay_forest_t::iterator position(unwrap(node)); ! position->origin_m = origin; ! position->extents_m = extents; } --- 230,237 ---- void ui_overlay_t::implementation_t::place(position_t node, const point_2d_t& origin, const extents_t& extents) { ! overlay_forest_t::iterator position(unwrap(node)); ! position->origin_m = origin; ! position->extents_m = extents; } *************** *** 240,270 **** void ui_overlay_t::implementation_t::framing(bool do_framing) { ! assert(source_m); ! framing_m = do_framing; ! if (!do_framing) ! { ! //set_control_invalid(control_m); ! } ! else ! { ! HWND main_window(source_m);//::GetAncestor(source_m, GA_ROOT)); ! HDC context(::GetWindowDC(main_window)); ! draw_element_set_t tick_set; ! overlay_forest_t::preorder_iterator first(tree_m.begin()); ! overlay_forest_t::preorder_iterator last(tree_m.end()); ! ::BringWindowToTop(main_window); ! for (; first != last; ++first) ! tick_extents(flatten_overlay_data(first.base()), main_window, tick_set); ! if (!tick_set.empty()) ! adobe::for_each(tick_set, boost::bind(&implementation_t::draw_tick, boost::ref(*this), context, _1)); ! ::ReleaseDC(main_window, context); ! } } --- 240,270 ---- void ui_overlay_t::implementation_t::framing(bool do_framing) { ! assert(source_m); ! framing_m = do_framing; ! if (!do_framing) ! { ! //set_control_invalid(control_m); ! } ! else ! { ! HWND main_window(source_m);//::GetAncestor(source_m, GA_ROOT)); ! HDC context(::GetWindowDC(main_window)); ! draw_element_set_t tick_set; ! overlay_forest_t::preorder_iterator first(tree_m.begin()); ! overlay_forest_t::preorder_iterator last(tree_m.end()); ! ::BringWindowToTop(main_window); ! for (; first != last; ++first) ! tick_extents(flatten_overlay_data(first.base()), main_window, tick_set); ! if (!tick_set.empty()) ! adobe::for_each(tick_set, boost::bind(&implementation_t::draw_tick, boost::ref(*this), context, _1)); ! ::ReleaseDC(main_window, context); ! } } *************** *** 273,289 **** overlay_data_t ui_overlay_t::implementation_t::flatten_overlay_data(overlay_forest_t::iterator iter) { ! overlay_data_t result; ! point_2d_t& origin(result.origin_m); ! overlay_forest_t::iterator last(tree_m.end()); ! result.extents_m = iter->extents_m; ! for (; iter != last; iter = find_parent(iter)) ! { ! origin.x_m += iter->origin_m.x_m; ! origin.y_m += iter->origin_m.y_m; ! } ! return result; } --- 273,289 ---- overlay_data_t ui_overlay_t::implementation_t::flatten_overlay_data(overlay_forest_t::iterator iter) { ! overlay_data_t result; ! point_2d_t& origin(result.origin_m); ! overlay_forest_t::iterator last(tree_m.end()); ! result.extents_m = iter->extents_m; ! for (; iter != last; iter = find_parent(iter)) ! { ! origin.x_m += iter->origin_m.x_m; ! origin.y_m += iter->origin_m.y_m; ! } ! return result; } *************** *** 292,353 **** void ui_overlay_t::implementation_t::tick_extents(const overlay_data_t& overlay_data, HWND main_window, draw_element_set_t& set) { ! typedef draw_element_t de_t; ! static const long tick(3); ! static COLORREF blue(RGB(0, 0, 255)); ! static COLORREF red(RGB(255, 0, 0)); ! const point_2d_t& position(overlay_data.origin_m); ! const extents_t& extents(overlay_data.extents_m); ! RECT extra(get_window_client_offset_rect(main_window)); ! long top(position.y_m + extra.top - 1); ! long left(position.x_m + extra.left); ! long bottom(top + extents.height() - 1); ! long right(left + extents.width()); ! long tick_width(std::min(tick, extents.width())); ! long tick_height(std::min(tick, extents.height())); ! long tick_start_right(std::max(right - tick, left)); ! long tick_start_bottom(std::max(bottom - tick, top)); ! RECT top_left_rect = { left, top, left + tick_width, top + tick_height }; ! RECT top_right_rect = { tick_start_right, top, tick_start_right + tick_width, top + tick_height }; ! RECT bottom_left_rect = { left, tick_start_bottom + 1, left + tick_width + 1, tick_start_bottom + tick_height }; ! RECT bottom_right_rect = { tick_start_right - 1, tick_start_bottom + 1, tick_start_right + tick_width, tick_start_bottom + tick_height }; ! set.push_back(de_t(de_t::element_type_top_left, top_left_rect, blue)); ! set.push_back(de_t(de_t::element_type_top_right, top_right_rect, blue)); ! set.push_back(de_t(de_t::element_type_bottom_left, bottom_left_rect, blue)); ! set.push_back(de_t(de_t::element_type_bottom_right, bottom_right_rect, blue)); ! { ! guide_set_t::const_iterator iter(extents.horizontal().poi_m.begin()); ! guide_set_t::const_iterator last(extents.horizontal().poi_m.end()); ! for (; iter != last; ++iter) ! { ! guide_set_t::value_type cur(*iter); ! long poi(left + cur); ! RECT top_tick = { poi, top, poi + 1, top + tick_height }; ! RECT bottom_tick = { poi, bottom - tick_height, poi + 1, bottom }; ! set.push_back(de_t(de_t::element_type_horizontal_poi, top_tick, red)); ! set.push_back(de_t(de_t::element_type_horizontal_poi, bottom_tick, red)); ! } ! } ! { ! guide_set_t::const_iterator iter(extents.vertical().poi_m.begin()); ! guide_set_t::const_iterator last(extents.vertical().poi_m.end()); ! for (; iter != last; ++iter) ! { ! guide_set_t::value_type cur(*iter); ! long poi(top + cur); ! RECT left_tick = { left, poi, left + tick_width, poi + 1 }; ! RECT right_tick = { right - tick_width, poi, right, poi + 1 }; ! set.push_back(de_t(de_t::element_type_vertical_poi, left_tick, red)); ! set.push_back(de_t(de_t::element_type_vertical_poi, right_tick, red)); ! } ! } } --- 292,353 ---- void ui_overlay_t::implementation_t::tick_extents(const overlay_data_t& overlay_data, HWND main_window, draw_element_set_t& set) { ! typedef draw_element_t de_t; ! static const long tick(3); ! static COLORREF blue(RGB(0, 0, 255)); ! static COLORREF red(RGB(255, 0, 0)); ! const point_2d_t& position(overlay_data.origin_m); ! const extents_t& extents(overlay_data.extents_m); ! RECT extra(get_window_client_offset_rect(main_window)); ! long top(position.y_m + extra.top - 1); ! long left(position.x_m + extra.left); ! long bottom(top + extents.height() - 1); ! long right(left + extents.width()); ! long tick_width(std::min(tick, extents.width())); ! long tick_height(std::min(tick, extents.height())); ! long tick_start_right(std::max(right - tick, left)); ! long tick_start_bottom(std::max(bottom - tick, top)); ! RECT top_left_rect = { left, top, left + tick_width, top + tick_height }; ! RECT top_right_rect = { tick_start_right, top, tick_start_right + tick_width, top + tick_height }; ! RECT bottom_left_rect = { left, tick_start_bottom + 1, left + tick_width + 1, tick_start_bottom + tick_height }; ! RECT bottom_right_rect = { tick_start_right - 1, tick_start_bottom + 1, tick_start_right + tick_width, tick_start_bottom + tick_height }; ! set.push_back(de_t(de_t::element_type_top_left, top_left_rect, blue)); ! set.push_back(de_t(de_t::element_type_top_right, top_right_rect, blue)); ! set.push_back(de_t(de_t::element_type_bottom_left, bottom_left_rect, blue)); ! set.push_back(de_t(de_t::element_type_bottom_right, bottom_right_rect, blue)); ! { ! guide_set_t::const_iterator iter(extents.horizontal().poi_m.begin()); ! guide_set_t::const_iterator last(extents.horizontal().poi_m.end()); ! for (; iter != last; ++iter) ! { ! guide_set_t::value_type cur(*iter); ! long poi(left + cur); ! RECT top_tick = { poi, top, poi + 1, top + tick_height }; ! RECT bottom_tick = { poi, bottom - tick_height, poi + 1, bottom }; ! set.push_back(de_t(de_t::element_type_horizontal_poi, top_tick, red)); ! set.push_back(de_t(de_t::element_type_horizontal_poi, bottom_tick, red)); ! } ! } ! { ! guide_set_t::const_iterator iter(extents.vertical().poi_m.begin()); ! guide_set_t::const_iterator last(extents.vertical().poi_m.end()); ! for (; iter != last; ++iter) ! { ! guide_set_t::value_type cur(*iter); ! long poi(top + cur); ! RECT left_tick = { left, poi, left + tick_width, poi + 1 }; ! RECT right_tick = { right - tick_width, poi, right, poi + 1 }; ! set.push_back(de_t(de_t::element_type_vertical_poi, left_tick, red)); ! set.push_back(de_t(de_t::element_type_vertical_poi, right_tick, red)); ! } ! } } *************** *** 356,412 **** void ui_overlay_t::implementation_t::draw_tick(HDC context, const draw_element_set_t::value_type& element) { ! typedef draw_element_set_t::value_type desvt_t; ! coord_set_t points; ! long top(element.rect_m.top + 1); ! long left(element.rect_m.left); ! long bottom(element.rect_m.bottom + 1); ! long right(element.rect_m.right - 1); ! coord_t top_left = { left, top }; ! coord_t top_right = { right, top }; ! coord_t bottom_left = { left, bottom }; ! coord_t bottom_right = { right, bottom }; ! HPEN pen(::CreatePen(PS_SOLID, 1, element.color_m)); ! HPEN old_pen((HPEN) SelectObject(context, pen)); ! if (element.type_m == desvt_t::element_type_top_left) ! { ! points.push_back(top_right); ! points.push_back(top_left); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_top_right) ! { ! points.push_back(top_left); ! points.push_back(top_right); ! points.push_back(bottom_right); ! } ! else if (element.type_m == desvt_t::element_type_bottom_left) ! { ! points.push_back(top_left); ! points.push_back(bottom_left); ! points.push_back(bottom_right); ! } ! else if (element.type_m == desvt_t::element_type_bottom_right) ! { ! points.push_back(top_right); ! points.push_back(bottom_right); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_horizontal_poi) ! { ! points.push_back(top_left); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_vertical_poi) ! { ! points.push_back(top_left); ! points.push_back(top_right); ! } ! draw_line_path(context, points); ! // clean up pen work SelectObject(context, old_pen); DeleteObject(pen); --- 356,412 ---- void ui_overlay_t::implementation_t::draw_tick(HDC context, const draw_element_set_t::value_type& element) { ! typedef draw_element_set_t::value_type desvt_t; ! coord_set_t points; ! long top(element.rect_m.top + 1); ! long left(element.rect_m.left); ! long bottom(element.rect_m.bottom + 1); ! long right(element.rect_m.right - 1); ! coord_t top_left = { left, top }; ! coord_t top_right = { right, top }; ! coord_t bottom_left = { left, bottom }; ! coord_t bottom_right = { right, bottom }; ! HPEN pen(::CreatePen(PS_SOLID, 1, element.color_m)); ! HPEN old_pen((HPEN) SelectObject(context, pen)); ! if (element.type_m == desvt_t::element_type_top_left) ! { ! points.push_back(top_right); ! points.push_back(top_left); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_top_right) ! { ! points.push_back(top_left); ! points.push_back(top_right); ! points.push_back(bottom_right); ! } ! else if (element.type_m == desvt_t::element_type_bottom_left) ! { ! points.push_back(top_left); ! points.push_back(bottom_left); ! points.push_back(bottom_right); ! } ! else if (element.type_m == desvt_t::element_type_bottom_right) ! { ! points.push_back(top_right); ! points.push_back(bottom_right); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_horizontal_poi) ! { ! points.push_back(top_left); ! points.push_back(bottom_left); ! } ! else if (element.type_m == desvt_t::element_type_vertical_poi) ! { ! points.push_back(top_left); ! points.push_back(top_right); ! } ! draw_line_path(context, points); ! // clean up pen work SelectObject(context, old_pen); DeleteObject(pen); Index: ui_core_implementation.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/win32/ui_core_implementation.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ui_core_implementation.cpp 2 Feb 2006 09:10:30 -0000 1.2 --- ui_core_implementation.cpp 3 Feb 2006 18:33:37 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt [...8237 lines suppressed...] ! HWND static_disable_ref(adobe::view_for_element<HWND>(element.implementation().static_disabled_text_m)); ! // HWND scroll_ref(adobe::view_for_element<HWND>(element.implementation().scroll_control_m)); ! HWND label_ref(adobe::view_for_element<HWND>(element.implementation().get_label())); ! HWND popup_ref(adobe::view_for_element<HWND>(element.implementation().get_popup())); ! HWND popup_static_disable_ref(adobe::view_for_element<HWND>(element.implementation().get_popup().implementation().static_disabled_text_m)); ! display_t::position_t result; ! // if (scroll_ref) result = display.insert<HWND>(parent, scroll_ref); ! // else ! result = display.insert<HWND>(parent, ref); ! if (label_ref) display.insert<HWND>(parent, label_ref); ! if (static_disable_ref) display.insert<HWND>(parent, static_disable_ref); ! if (popup_static_disable_ref) display.insert<HWND>(parent, popup_static_disable_ref); ! if (popup_ref) display.insert<HWND>(parent, popup_ref); ! return result; } Index: display.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/win32/display.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** display.cpp 24 Jan 2006 19:38:49 -0000 1.1 --- display.cpp 3 Feb 2006 18:33:37 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 24,32 **** struct view_wrap { ! explicit view_wrap(HWND ref) : ! ref_m(ref) ! { } ! HWND ref_m; }; --- 24,32 ---- struct view_wrap { ! explicit view_wrap(HWND ref) : ! ref_m(ref) ! { } ! HWND ref_m; }; *************** *** 35,39 **** HWND unwrap(adobe::display_t::position_t& position) { ! return (boost::any_cast<view_wrap>(position)).ref_m; } --- 35,39 ---- HWND unwrap(adobe::display_t::position_t& position) { ! return (boost::any_cast<view_wrap>(position)).ref_m; } *************** *** 42,46 **** adobe::display_t::position_t wrap(HWND view) { ! return adobe::display_t::position_t(view_wrap(view)); } --- 42,46 ---- adobe::display_t::position_t wrap(HWND view) { ! return adobe::display_t::position_t(view_wrap(view)); } *************** *** 52,56 **** #if 0 ! #pragma mark - #endif --- 52,56 ---- #if 0 ! #pragma mark - #endif *************** *** 63,69 **** display_t& get_main_display() { ! static display_t display_s; ! return display_s; } --- 63,69 ---- display_t& get_main_display() { ! static display_t display_s; ! return display_s; } *************** *** 72,78 **** struct display_t::implementation_t { ! void erase(display_t::position_t& position); ! HWND root_m; }; --- 72,78 ---- struct display_t::implementation_t { ! void erase(display_t::position_t& position); ! HWND root_m; }; *************** *** 92,96 **** #if 0 ! #pragma mark - #endif --- 92,96 ---- #if 0 ! #pragma mark - #endif *************** *** 98,130 **** display_t::display_t() : ! object_m(new implementation_t()) ! { } display_t::~display_t() ! { delete object_m; object_m = 0; } display_t::implementation_t& display_t::implementation() ! { return *object_m; } const display_t::implementation_t& display_t::implementation() const ! { return *object_m; } template <typename DisplayElement> void display_t::set_root(DisplayElement&) ! { } template <> void display_t::set_root<HWND>(HWND& root) ! { object_m->root_m = root; } display_t::position_t display_t::root() ! { return wrap(object_m->root_m); } void display_t::erase(position_t& position) ! { return object_m->erase(position); } template <typename DisplayElement> display_t::position_t display_t::insert(position_t& parent, DisplayElement& element) ! { return insert(parent, adobe::view_for_element<HWND>(element)); } /****************************************************************************************************/ --- 98,130 ---- display_t::display_t() : ! object_m(new implementation_t()) ! { } display_t::~display_t() ! { delete object_m; object_m = 0; } display_t::implementation_t& display_t::implementation() ! { return *object_m; } const display_t::implementation_t& display_t::implementation() const ! { return *object_m; } template <typename DisplayElement> void display_t::set_root(DisplayElement&) ! { } template <> void display_t::set_root<HWND>(HWND& root) ! { object_m->root_m = root; } display_t::position_t display_t::root() ! { return wrap(object_m->root_m); } void display_t::erase(position_t& position) ! { return object_m->erase(position); } template <typename DisplayElement> display_t::position_t display_t::insert(position_t& parent, DisplayElement& element) ! { return insert(parent, adobe::view_for_element<HWND>(element)); } /****************************************************************************************************/ *************** *** 133,146 **** display_t::position_t display_t::insert<HWND>(position_t& parent, HWND& element) { ! if (parent.type() == typeid(view_wrap)) ! { ! HWND parent_view(unwrap(parent)); ! if (::SetParent(element, parent_view) == 0) throw std::runtime_error("display_t::insert<HWND>"); // ADOBE_REQUIRE_STATUS(::GetLastError()); ! assert(::GetParent(element) == parent_view); ! } ! return wrap(element); } --- 133,146 ---- display_t::position_t display_t::insert<HWND>(position_t& parent, HWND& element) { ! if (parent.type() == typeid(view_wrap)) ! { ! HWND parent_view(unwrap(parent)); ! if (::SetParent(element, parent_view) == 0) throw std::runtime_error("display_t::insert<HWND>"); // ADOBE_REQUIRE_STATUS(::GetLastError()); ! assert(::GetParent(element) == parent_view); ! } ! return wrap(element); } *************** *** 148,152 **** #if 0 ! #pragma mark - #endif --- 148,152 ---- #if 0 ! #pragma mark - #endif *************** *** 155,164 **** void display_t::implementation_t::erase(display_t::position_t&) { ! // REVISIT (fbrereto) : What should we do here? ! // 1) Call DetachSubView on the position? ! // 2) Call erase recursively for all children of the position? ! // 3) Invalidate (wipe) the position data? ! // 4) Invoke some (currently nonexistent) detach() callback for the client? ! // 4a) With what parameters, considering questions 1, 2, & 3? } --- 155,164 ---- void display_t::implementation_t::erase(display_t::position_t&) { ! // REVISIT (fbrereto) : What should we do here? ! // 1) Call DetachSubView on the position? ! // 2) Call erase recursively for all children of the position? ! // 3) Invalidate (wipe) the position data? ! // 4) Invoke some (currently nonexistent) detach() callback for the client? ! // 4a) With what parameters, considering questions 1, 2, & 3? } Index: metrics.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/sources/win32/metrics.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** metrics.cpp 24 Jan 2006 19:38:49 -0000 1.1 --- metrics.cpp 3 Feb 2006 18:33:37 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 41,211 **** class metrics_win32_t : public metrics_t { ! // ! /// Store the class name of the window which we're currently examining. ! // ! std::wstring class_name_m; protected: ! // ! /// Return the window class which we are currently returing metrics for. ! /// ! /// \return the current window class. ! // ! std::wstring get_window_class() const { ! return class_name_m; ! } public: ! // ! // from metrics_t ! // ! bool set_window(HWND window) ! { ! WCHAR class_name_buf[50]; ! if (!GetClassNameW(window, class_name_buf, 50)) return false; ! class_name_m = class_name_buf; ! return true; ! } ! bool get_font(int widget_type, LOGFONTW& out_font) const ! { ! // ! // On plain windows everything uses DEFAULT_GUI_FONT. ! // ! HGDIOBJ font = GetStockObject(DEFAULT_GUI_FONT); ! if (!font) return false; ! // ! // Extract a LOGFONTW from the HFONT. ! // ! int rv = GetObject(font, sizeof(out_font), reinterpret_cast<LPVOID>(&out_font)); ! DeleteObject(font); ! return (rv != 0); ! } ! bool get_font_metrics(int widget_type, TEXTMETRIC& out_metrics) const ! { ! // ! // Try to use the font from get_font before we fall back to DEFAULT_GUI_FONT. ! // ! LOGFONTW logical_font = { 0 }; ! HGDIOBJ font = 0; ! HDC tmp_dc = GetDC(0); ! if (get_font(widget_type, logical_font)) ! { ! font = (HGDIOBJ)CreateFontIndirectW(&logical_font); ! } ! if (!font) font = GetStockObject(DEFAULT_GUI_FONT); ! // ! // Get the metrics. ! // ! HGDIOBJ oldFont = SelectObject(tmp_dc, font); ! BOOL have_metrics = GetTextMetrics(tmp_dc, &out_metrics); ! // ! // Clean up. ! // ! DeleteObject(SelectObject(tmp_dc, oldFont)); ! ReleaseDC(0, tmp_dc); ! return hackery::cast<bool>(have_metrics); ! } ! bool get_text_extents(int widget_type, std::wstring text, RECT& out_extents) const ! { ! // ! // Create the font and select it into a temporary device context. ! // ! HDC tmp_dc = GetDC(0); ! LOGFONTW logical_font = {0}; ! HGDIOBJ font = 0; ! // ! // Try to use get_font, in case there is another font we're meant ! // to use. Then fallback on DEFAULT_GUI_FONT. ! // ! if (get_font(widget_type, logical_font)) ! { ! font = (HGDIOBJ)CreateFontIndirectW(&logical_font); ! } ! if (!font) font = GetStockObject(DEFAULT_GUI_FONT); ! // ! // Extract the extents. ! // ! HGDIOBJ original_font = SelectObject(tmp_dc, font); ! SIZE out_size = {0, 0}; ! BOOL have_extents = GetTextExtentPoint32W(tmp_dc, text.c_str(), static_cast<int>(text.size()), &out_size); ! // ! // Clean up, and convert the size to a rect. ! // ! DeleteObject(SelectObject(tmp_dc, original_font)); ! ReleaseDC(0, tmp_dc); ! out_extents.left = 0; out_extents.top = 0; ! out_extents.right = out_size.cx; ! out_extents.bottom = out_size.cy; ! return hackery::cast<bool>(have_extents); ! } ! bool get_integer(int widget_type, int measurement, int& out_val) const ! { ! if ((widget_type == CP_DROPDOWNBUTTON) && (measurement == TMT_BORDERSIZE) && (class_name_m == L"ComboBox")) ! { ! out_val = 1; ! return true; ! } ! if ((widget_type == EP_EDITTEXT) && (measurement == TMT_BORDERSIZE)) ! { ! out_val = 1; ! return true; ! } ! out_val = 0; ! return false; ! } ! bool get_size(int widget_type, THEMESIZE measurement, SIZE& out_size) const ! { ! if (class_name_m == L"Button") ! { ! if ((widget_type == BP_CHECKBOX) || (widget_type == BP_RADIOBUTTON)) ! { ! // ! // Strictly the width of the checkbox widget is 13 pixels. ! // This adds some padding so that letters don't get clipped. ! // ! out_size.cx = 23; out_size.cy = 13; ! return true; ! } ! if (widget_type == BP_GROUPBOX) ! { ! out_size.cx = 8; out_size.cy = 8; ! return true; ! } ! out_size.cx = 0; out_size.cy = 0; ! return true; ! } ! out_size.cx = 0; out_size.cy = 0; ! return false; ! } ! bool get_margins(int widget_type, MARGINS& out_margins) const ! { ! if ((class_name_m == L"Button") && (widget_type == BP_PUSHBUTTON)) ! { ! out_margins.cxLeftWidth = 3; out_margins.cxRightWidth = 3; ! out_margins.cyTopHeight = 3; out_margins.cyBottomHeight = 3; ! return true; ! } ! return false; ! } ! bool get_button_text_margins(int widget_type, RECT& out_margins) const { ! if ((class_name_m == L"Button") && (widget_type == BP_CHECKBOX)) ! { ! out_margins.top = 1; out_margins.left = 1; ! out_margins.bottom = 1; out_margins.right = 1; ! return true; ! } ! return false; ! } ! bool using_styles() const ! { ! return false; ! } ! void draw_parent_background(HWND window, HDC dc) ! { ! // ! // REVISIT (ralpht): This function doesn't actually get called when visual ! // styles aren't available, so there's no implementation here. That ! // may not always be the case, however... ! // ! throw std::runtime_error("metrics::draw_parent_background not implemented without visual styles enabled"); ! } }; --- 41,211 ---- class metrics_win32_t : public metrics_t { ! // ! /// Store the class name of the window which we're currently examining. ! // ! std::wstring class_name_m; protected: ! // ! /// Return the window class which we are currently returing metrics for. ! /// ! /// \return the current window class. ! // ! std::wstring get_window_class() const { ! return class_name_m; ! } public: ! // ! // from metrics_t ! // ! bool set_window(HWND window) ! { ! WCHAR class_name_buf[50]; ! if (!GetClassNameW(window, class_name_buf, 50)) return false; ! class_name_m = class_name_buf; ! return true; ! } ! bool get_font(int widget_type, LOGFONTW& out_font) const ! { ! // ! // On plain windows everything uses DEFAULT_GUI_FONT. ! // ! HGDIOBJ font = GetStockObject(DEFAULT_GUI_FONT); ! if (!font) return false; ! // ! // Extract a LOGFONTW from the HFONT. ! // ! int rv = GetObject(font, sizeof(out_font), reinterpret_cast<LPVOID>(&out_font)); ! DeleteObject(font); ! return (rv != 0); ! } ! bool get_font_metrics(int widget_type, TEXTMETRIC& out_metrics) const ! { ! // ! // Try to use the font from get_font before we fall back to DEFAULT_GUI_FONT. ! // ! LOGFONTW logical_font = { 0 }; ! HGDIOBJ font = 0; ! HDC tmp_dc = GetDC(0); ! if (get_font(widget_type, logical_font)) ! { ! font = (HGDIOBJ)CreateFontIndirectW(&logical_font); ! } ! if (!font) font = GetStockObject(DEFAULT_GUI_FONT); ! // ! // Get the metrics. ! // ! HGDIOBJ oldFont = SelectObject(tmp_dc, font); ! BOOL have_metrics = GetTextMetrics(tmp_dc, &out_metrics); ! // ! // Clean up. ! // ! DeleteObject(SelectObject(tmp_dc, oldFont)); ! ReleaseDC(0, tmp_dc); ! return hackery::cast<bool>(have_metrics); ! } ! bool get_text_extents(int widget_type, std::wstring text, RECT& out_extents) const ! { ! // ! // Create the font and select it into a temporary device context. ! // ! HDC tmp_dc = GetDC(0); ! LOGFONTW logical_font = {0}; ! HGDIOBJ font = 0; ! // ! // Try to use get_font, in case there is another font we're meant ! // to use. Then fallback on DEFAULT_GUI_FONT. ! // ! if (get_font(widget_type, logical_font)) ! { ! font = (HGDIOBJ)CreateFontIndirectW(&logical_font); ! } ! if (!font) font = GetStockObject(DEFAULT_GUI_FONT); ! // ! // Extract the extents. ! // ! HGDIOBJ original_font = SelectObject(tmp_dc, font); ! SIZE out_size = {0, 0}; ! BOOL have_extents = GetTextExtentPoint32W(tmp_dc, text.c_str(), static_cast<int>(text.size()), &out_size); ! // ! // Clean up, and convert the size to a rect. ! // ! DeleteObject(SelectObject(tmp_dc, original_font)); ! ReleaseDC(0, tmp_dc); ! out_extents.left = 0; out_extents.top = 0; ! out_extents.right = out_size.cx; ! out_extents.bottom = out_size.cy; ! return hackery::cast<bool>(have_extents); ! } ! bool get_integer(int widget_type, int measurement, int& out_val) const ! { ! if ((widget_type == CP_DROPDOWNBUTTON) && (measurement == TMT_BORDERSIZE) && (class_name_m == L"ComboBox")) ! { ! out_val = 1; ! return true; ! } ! if ((widget_type == EP_EDITTEXT) && (measurement == TMT_BORDERSIZE)) ! { ! out_val = 1; ! return true; ! } ! out_val = 0; ! return false; ! } ! bool get_size(int widget_type, THEMESIZE measurement, SIZE& out_size) const ! { ! if (class_name_m == L"Button") ! { ! if ((widget_type == BP_CHECKBOX) || (widget_type == BP_RADIOBUTTON)) ! { ! // ! // Strictly the width of the checkbox widget is 13 pixels. ! // This adds some padding so that letters don't get clipped. ! // ! out_size.cx = 23; out_size.cy = 13; ! return true; ! } ! if (widget_type == BP_GROUPBOX) ! { ! out_size.cx = 8; out_size.cy = 8; ! return true; ! } ! out_size.cx = 0; out_size.cy = 0; ! return true; ! } ! out_size.cx = 0; out_size.cy = 0; ! return false; ! } ! bool get_margins(int widget_type, MARGINS& out_margins) const ! { ! if ((class_name_m == L"Button") && (widget_type == BP_PUSHBUTTON)) ! { ! out_margins.cxLeftWidth = 3; out_margins.cxRightWidth = 3; ! out_margins.cyTopHeight = 3; out_margins.cyBottomHeight = 3; ! return true; ! } ! return false; ! } ! bool get_button_text_margins(int widget_type, RECT& out_margins) const { ! if ((class_name_m == L"Button") && (widget_type == BP_CHECKBOX)) ! { ! out_margins.top = 1; out_margins.left = 1; ! out_margins.bottom = 1; out_margins.right = 1; ! return true; ! } ! return false; ! } ! bool using_styles() const ! { ! return false; ! } ! void draw_parent_background(HWND window, HDC dc) ! { ! // ! // REVISIT (ralpht): This function doesn't actually get called when visual ! // styles aren't available, so there's no implementation here. That ! // may not always be the case, however... ! // ! throw std::runtime_error("metrics::draw_parent_background not implemented without visual styles enabled"); ! } }; *************** *** 219,475 **** class metrics_uxtheme_t : public metrics_win32_t { ! typedef metrics_win32_t _super; ! // ! // Handle to the UxTheme.DLL. ! // ! HMODULE theme_dll_m; ! // ! // Handle to the theme which we are currently using. ! // ! HTHEME theme_m; ! // ! // Technically all of these calls are supposed to use a state parameter. We are ! // only obtaining metrics, rather than drawing, so we don't actually need to ! // specify any particular state (as metrics should be invariant over all states). ! // ! // According to the tmschema.h (in the Platform SDK) a state of 1 should always ! // work. ! // ! // const int kState; ! // ! // Because we open UxTheme.DLL dynamically we need to keep function pointers into ! // the library. These are those. ! // ! typedef HTHEME (__stdcall *OpenThemeData_t)(HWND hwnd, LPCWSTR pszClassList); ! typedef HRESULT (__stdcall *CloseThemeData_t)(HTHEME hTheme); ! typedef HRESULT (__stdcall *GetThemeMargins_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, int iPropId, RECT* prc, MARGINS* pMargins); ! typedef HRESULT (__stdcall *GetThemePartSize_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, RECT* pRect, enum THEMESIZE eSize, SIZE* psz); ! typedef HRESULT (__stdcall *GetThemeInt_t)(HTHEME hTheme, int iPartId, int iStateId, int iPropId, int* piVal); ! typedef HRESULT (__stdcall *GetThemeTextExtent_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, LPCWSTR pszText, int iCharCount, DWORD dwTextFlags, const RECT* pBoundingRect, RECT* pExtentRect); ! typedef HRESULT (__stdcall *GetThemeTextMetrics_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, TEXTMETRIC* ptm); ! typedef HRESULT (__stdcall *GetThemeFont_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, int iPropId, LOGFONTW* pFont); ! typedef HRESULT (__stdcall *GetThemeSysFont_t)(HTHEME hTheme, int iFontId, LOGFONTW* pFont); ! typedef HRESULT (__stdcall *DrawThemeParentBackground_t)(HWND window, HDC dc, LPRECT prc); ! typedef BOOL (__stdcall *IsThemeActive_t)(void); ! OpenThemeData_t OpenThemeDataPtr; ! CloseThemeData_t CloseThemeDataPtr; ! GetThemeMargins_t GetThemeMarginsPtr; ! GetThemePartSize_t GetThemePartSizePtr; ! GetThemeInt_t GetThemeIntPtr; ! GetThemeTextExtent_t GetThemeTextExtentPtr; ! GetThemeTextMetrics_t GetThemeTextMetricsPtr; ! GetThemeFont_t GetThemeFontPtr; ! GetThemeSysFont_t GetThemeSysFontPtr; ! IsThemeActive_t IsThemeActivePtr; ! DrawThemeParentBackground_t DrawThemeParentBackgroundPtr; ! // ! // We only ever try to load UxTheme.DLL once, this boolean tells us if we were ! // successful. ! // ! bool loaded_m; ! // ! /// The HWND we are currently inspecting. ! // ! HWND window_m; public: ! metrics_uxtheme_t() : theme_dll_m(0), theme_m(0), OpenThemeDataPtr(0), CloseThemeDataPtr(0), ! GetThemeMarginsPtr(0), GetThemePartSizePtr(0), GetThemeIntPtr(0), ! GetThemeTextExtentPtr(0), GetThemeTextMetricsPtr(0), GetThemeFontPtr(0), ! GetThemeSysFontPtr(0), IsThemeActivePtr(0), DrawThemeParentBackgroundPtr(0), ! loaded_m(false), window_m(0) ! { ! // ! // Try to load the UxTheme library, if we can. ! // ! theme_dll_m = LoadLibrary(__T("UxTheme.dll")); ! if (!theme_dll_m) return; ! // ! // Load the addresses of the UxTheme functions. ! // ! if (!(OpenThemeDataPtr = (OpenThemeData_t)GetProcAddress(theme_dll_m, "OpenThemeData"))) return; ! if (!(CloseThemeDataPtr = (CloseThemeData_t)GetProcAddress(theme_dll_m, "CloseThemeData"))) return; ! if (!(GetThemeMarginsPtr = (GetThemeMargins_t)GetProcAddress(theme_dll_m, "GetThemeMargins"))) return; ! if (!(GetThemePartSizePtr = (GetThemePartSize_t)GetProcAddress(theme_dll_m, "GetThemePartSize"))) return; ! if (!(GetThemeIntPtr = (GetThemeInt_t)GetProcAddress(theme_dll_m, "GetThemeInt"))) return; ! if (!(GetThemeTextExtentPtr = (GetThemeTextExtent_t)GetProcAddress(theme_dll_m, "GetThemeTextExtent"))) return; ! if (!(GetThemeTextMetricsPtr = (GetThemeTextMetrics_t)GetProcAddress(theme_dll_m, "GetThemeTextMetrics"))) return; ! if (!(GetThemeFontPtr = (GetThemeFont_t)GetProcAddress(theme_dll_m, "GetThemeFont"))) return; ! if (!(GetThemeSysFontPtr = (GetThemeSysFont_t)GetProcAddress(theme_dll_m, "GetThemeSysFont"))) return; ! if (!(IsThemeActivePtr = (IsThemeActive_t)GetProcAddress(theme_dll_m, "IsThemeActive"))) return; ! if (!(DrawThemeParentBackgroundPtr = (DrawThemeParentBackground_t)GetProcAddress(theme_dll_m, "DrawThemeParentBackground"))) return; ! // ! // All loaded! ! // ! loaded_m = true; ! } ! virtual ~metrics_uxtheme_t() ! { ! if (theme_dll_m) FreeLibrary(theme_dll_m); ! } ! // ! /// This function returns true if the theme is active. If the theme ! /// is not active then the plain win32 metrics object should be used. ! // ! bool theme_active() const ! { ! if (!loaded_m) return false; ! return hackery::cast<bool>((*IsThemeActivePtr)()); ! } ! // ! // from metrics_t ! // ! bool set_window(HWND win) ! { ! if (!_super::set_window(win)) return false; ! // ! // Keep this window around. ! // ! window_m = win; ! // ! // Close any already open theme data, and load up the new ! // data. ! // ! if (theme_m) (*CloseThemeDataPtr)(theme_m); ! // The next section of code tries to account for the fact that the names required ! // by OpenThemeData are different from the "class name" used by CreateWindowEx ! // I am having trouble finding definitive documentation on these names, so I am ! // not going to clean this up and break it out into a reusable conversion function yet. ! // MM - 11/15/2005 ! static const wchar_t* class_names[] = { ! L"ComboBoxEx32", ! L"SysTabControl32", ! L"SysTreeView32", ! L"msctls_progress32", ! L"msctls_trackbar32", ! L"msctls_updown32", ! L"tooltips_class32", ! //L"Button", ! //L"ComboBox", ! //L"Edit", ! //L"ListBox", ! //L"NativeFontCtl", ! //L"ScrollBar", ! //L"Static", ! //L"SysAnimate32", ! //L"SysDateTimePick32", ! //L"SysIPAddress32", ! //L"SysListView32", ! //L"SysMonthCal32", ! //L"SysPager", ! //L"msctls_hotkey32", ! }; ! static const wchar_t* theme_names[] = { ! L"ComboBox", ! L"Tab", ! L"TreeView", ! L"Progress", ! L"Trackbar", ! L"Spin", ! L"Tooltip", ! //L"Button", ! //L"Edit", ! //L"Globals", ! //L"Header", ! //L"Menu", ! //L"Rebar", ! //L"Scrollbar", ! //L"Status", ! //L"Toolbar", ! //L"Window" ! }; ! const std::wstring& class_name = get_window_class(); ! const wchar_t *theme_name = class_name.c_str(); ! BOOST_STATIC_ASSERT(sizeof(class_names)==sizeof(theme_names)); ! const ptrdiff_t names_count = sizeof(class_names)/sizeof(wchar_t*); ! ! const wchar_t** i = class_names; ! while(i != &class_names[names_count] && std::wcscmp(*i, theme_name) != 0) ++i; ! if(i != &class_names[names_count]) ! theme_name = theme_names[i - class_names]; ! theme_m = (*OpenThemeDataPtr)(win, theme_name); ! return (theme_m != 0); ! } ! bool get_font(int widget_type, LOGFONTW& out_font) const ! { ! // ! // We need ensure that we have a handle to the theme before ! // continuing. ! // ! if (!theme_m) return false; ! if (widget_type != -1) ! { ! HDC tmp_dc = GetDC(0); ! HRESULT hr = (*GetThemeFontPtr)(theme_m, tmp_dc, widget_type, kState, TMT_FONT, &out_font); ! ReleaseDC(0,tmp_dc); ! if (hr == S_OK) return true; ! } ! // ! // This widget is a text label, most likely. Give it the ! // standard message box font. ! // ! if (S_OK == (*GetThemeSysFontPtr)(theme_m, TMT_MSGBOXFONT, &out_font)) ! return true; ! return false; ! } ! // ! // Previously we had implementations of get_font_metrics and get_text_extents ! // which used the UXTheme API. We were not getting the values back that we ! // expected, so we now use the Win32 API for getting those measurements (although ! // note that we still get the actual widget font with UxTheme). ! // ! bool get_integer(int widget_type, int measurement, int& out_val) const ! { ! // ! // We don't fallback from this function. ! // ! if ((!theme_m) || (widget_type == -1)) return false; ! return (S_OK == (*GetThemeIntPtr)(theme_m, widget_type, kState, measurement, &out_val)); ! } ! bool get_size(int widget_type, THEMESIZE measurement, SIZE& out_size) const ! { ! // ! // We don't fallback from this function. ! // ! if ((!theme_m) || (widget_type == -1)) return false; ! // ! // Create a temporary device context and call GetThemePartSize. ! // ! HDC tmp_dc = GetDC(0); ! HRESULT hr = (*GetThemePartSizePtr)(theme_m, tmp_dc, widget_type, kState, 0, measurement, &out_size); ! ReleaseDC(0, tmp_dc); ! return (hr == S_OK); ! } ! bool get_margins(int widget_type, MARGINS& out_margins) const ! { ! // ! // We don't fall back from this function. ! // ! if ((!theme_m) || (widget_type == -1)) return false; ! // ! // Use GetThemeMargins call to get the margins for this widget. ! // ! return (S_OK == (*GetThemeMarginsPtr)(theme_m, 0, widget_type, kState, TMT_CONTENTMARGINS, 0, &out_margins)); ! } ! bool get_button_text_margins(int widget_type, RECT& out_margins) const ! { ! // ! // Fallback if we're not using a theme. ! // ! if (!theme_m) return _super::get_button_text_margins(widget_type, out_margins); ! return hackery::cast<bool>(Button_GetTextMargin(window_m, &out_margins)); ! } ! bool using_styles() const { ! return theme_active(); ! } ! void draw_parent_background(HWND window, HDC dc) { ! if (!loaded_m) return; ! (*DrawThemeParentBackgroundPtr)(window, dc, 0); ! } }; /****************************************************************************************************/ --- 219,475 ---- class metrics_uxtheme_t : public metrics_win32_t { ! typedef metrics_win32_t _super; ! // ! // Handle to the UxTheme.DLL. ! // ! HMODULE theme_dll_m; ! // ! // Handle to the theme which we are currently using. ! // ! HTHEME theme_m; ! // ! // Technically all of these calls are supposed to use a state parameter. We are ! // only obtaining metrics, rather than drawing, so we don't actually need to ! // specify any particular state (as metrics should be invariant over all states). ! // ! // According to the tmschema.h (in the Platform SDK) a state of 1 should always ! // work. ! // ! // const int kState; ! // ! // Because we open UxTheme.DLL dynamically we need to keep function pointers into ! // the library. These are those. ! // ! typedef HTHEME (__stdcall *OpenThemeData_t)(HWND hwnd, LPCWSTR pszClassList); ! typedef HRESULT (__stdcall *CloseThemeData_t)(HTHEME hTheme); ! typedef HRESULT (__stdcall *GetThemeMargins_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, int iPropId, RECT* prc, MARGINS* pMargins); ! typedef HRESULT (__stdcall *GetThemePartSize_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, RECT* pRect, enum THEMESIZE eSize, SIZE* psz); ! typedef HRESULT (__stdcall *GetThemeInt_t)(HTHEME hTheme, int iPartId, int iStateId, int iPropId, int* piVal); ! typedef HRESULT (__stdcall *GetThemeTextExtent_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, LPCWSTR pszText, int iCharCount, DWORD dwTextFlags, const RECT* pBoundingRect, RECT* pExtentRect); ! typedef HRESULT (__stdcall *GetThemeTextMetrics_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, TEXTMETRIC* ptm); ! typedef HRESULT (__stdcall *GetThemeFont_t)(HTHEME hTheme, HDC hdc, int iPartId, int iStateId, int iPropId, LOGFONTW* pFont); ! typedef HRESULT (__stdcall *GetThemeSysFont_t)(HTHEME hTheme, int iFontId, LOGFONTW* pFont); ! typedef HRESULT (__stdcall *DrawThemeParentBackground_t)(HWND window, HDC dc, LPRECT prc); ! typedef BOOL (__stdcall *IsThemeActive_t)(void); ! OpenThemeData_t OpenThemeDataPtr; ! CloseThemeData_t CloseThemeDataPtr; ! GetThemeMargins_t GetThemeMarginsPtr; ! GetThemePartSize_t GetThemePartSizePtr; ! GetThemeInt_t GetThemeIntPtr; ! GetThemeTextExtent_t GetThemeTextExtentPtr; ! GetThemeTextMetrics_t GetThemeTextMetricsPtr; ! GetThemeFont_t GetThemeFontPtr; ! GetThemeSysFont_t GetThemeSysFontPtr; ! IsThemeActive_t IsThemeActivePtr; ! DrawThemeParentBackground_t DrawThemeParentBackgroundPtr; ! // ! // We only ever try to load UxTheme.DLL once, this boolean tells us if we were ! // successful. ! // ! bool loaded_m; ! // ! /// The HWND we are currently inspecting. ! // ! HWND window_m; public: ! metrics_uxtheme_t() : theme_dll_m(0), theme_m(0), OpenThemeDataPtr(0), CloseThemeDataPtr(0), ! GetThemeMarginsPtr(0), GetThemePartSizePtr(0), GetThemeIntPtr(0), ! GetThemeTextExtentPtr(0), GetThemeTextMetricsPtr(0), GetThemeFontPtr(0), ! GetThemeSysFontPtr(0), IsThemeActivePtr(0), DrawThemeParentBackgroundPtr(0), ! loaded_m(false), window_m(0) ! { ! // ! // Try to load the UxTheme library, if we can. ! // ! theme_dll_m = LoadLibrary(__T("UxTheme.dll")); ! if (!theme_dll_m) return; ! // ! // Load the addresses of the UxTheme functions. ! // ! if (!(OpenThemeDataPtr = (OpenThemeData_t)GetProcAddress(theme_dll_m, "OpenThemeData"))) return; ! if (!(CloseThemeDataPtr = (CloseThemeData_t)GetProcAddress(theme_dll_m, "CloseThemeData"))) return; ! if (!(GetThemeMarginsPtr = (GetThemeMargins_t)GetProcAddress(theme_dll_m, "GetThemeMargins"))) return; ! if (!(GetThemePartSizePtr = (GetThemePartSize_t)GetProcAddress(theme_dll_m, "GetThemePartSize"))) return; ! if (!(GetThemeIntPtr = (GetThemeInt_t)GetProcAddress(theme_dll_m, "GetThemeInt"))) return; ! if (!(GetThemeTextExtentPtr = (GetThemeTextExtent_t)GetProcAddress(theme_dll_m, "GetThemeTextExtent"))) return; ! if (!(GetThemeTextMetricsPtr = (GetThemeTextMetrics_t)GetProcAddress(theme_dll_m, "GetThemeTextMetrics"))) return; ! if (!(GetThemeFontPtr = (GetThemeFont_t)GetProcAddress(theme_dll_m, "GetThemeFont"))) return; ! if (!(GetThemeSysFontPtr = (GetThemeSysFont_t)GetProcAddress(theme_dll_m, "GetThemeSysFont"))) return; ! if (!(IsThemeActivePtr = (IsThemeActive_t)GetProcAddress(theme_dll_m, "IsThemeActive"))) return; ! if (!(DrawThemeParentBackgroundPtr = (DrawThemeParentBackground_t)GetProcAddress(theme_dll_m, "DrawThemeParentBackground"))) return; ! // ! // All loaded! ! // ! loaded_m = true; ! } ! virtual ~metrics_uxtheme_t() ! { ! if (theme_dll_m) FreeLibrary(theme_dll_m); ! } ! // ! /// This function returns true if the theme is active. If the theme ! /// is not active then the plain win32 metrics object should be used. ! // ! bool theme_active() const ! { ! if (!loaded_m) return false; ! return hackery::cast<bool>((*IsThemeActivePtr)()); ! } ! // ! // from metrics_t ! // ! bool set_window(HWND win) ! { ! if (!_super::set_window(win)) return false; ! // ! // Keep this window around. ! // ! window_m = win; ! // ! // Close any already open theme data, and load up the new ! // data. ! // ! if (theme_m) (*CloseThemeDataPtr)(theme_m); ! // The next section of code tries to account for the fact that the names required ! // by OpenThemeData are different from the "class name" used by CreateWindowEx ! // I am having trouble finding definitive documentation on these names, so I am ! // not going to clean this up and break it out into a reusable conversion function yet. ! // MM - 11/15/2005 ! static const wchar_t* class_names[] = { ! L"ComboBoxEx32", ! L"SysTabControl32", ! L"SysTreeView32", ! L"msctls_progress32", ! L"msctls_trackbar32", ! L"msctls_updown32", ! L"tooltips_class32", ! //L"Button", ! //L"ComboBox", ! //L"Edit", ! //L"ListBox", ! //L"NativeFontCtl", ! //L"ScrollBar", ! //L"Static", ! //L"SysAnimate32", ! //L"SysDateTimePick32", ! //L"SysIPAddress32", ! //L"SysListView32", ! //L"SysMonthCal32", ! //L"SysPager", ! //L"msctls_hotkey32", ! }; ! static const wchar_t* theme_names[] = { ! L"ComboBox", ! L"Tab", ! L"TreeView", ! L"Progress", ! L"Trackbar", ! L"Spin", ! L"Tooltip", ! //L"Button", ! //L"Edit", ! //L"Globals", ! //L"Header", ! //L"Menu", ! //L"Rebar", ! //L"Scrollbar", ! //L"Status", ! //L"Toolbar", ! //L"Window" ! }; ! const std::wstring& class_name = get_window_class(); ! const wchar_t *theme_name = class_name.c_str(); ! BOOST_STATIC_ASSERT(sizeof(class_names)==sizeof(theme_names)); ! const ptrdiff_t names_count = sizeof(class_names)/sizeof(wchar_t*); ! ! const wchar_t** i = class_names; ! while(i != &class_names[names_count] && std::wcscmp(*i, theme_name) != 0) ++i; ! if(i != &class_names[names_count]) ! theme_name = theme_names[i - class_names]; ! ... [truncated message content] |
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources/examples Modified Files: enum_ops_example.cpp enum_ops_example_fail.cpp namespace.cpp namespace_fail.cpp specialization.cpp Log Message: asl 1.0.13 Index: enum_ops_example_fail.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples/enum_ops_example_fail.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** enum_ops_example_fail.cpp 8 Sep 2005 15:51:11 -0000 1.1 --- enum_ops_example_fail.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2001 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2001 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 27,46 **** enum Foo ! { ! foo_4 = 1 << 2, ! foo_8 = 1 << 3 ! }; enum Bar ! { ! bar_4 = 1 << 2, ! bar_8 = 1 << 3 ! }; enum Baz ! { ! baz_4 = 1 << 2, ! baz_8 = 1 << 3 ! }; ADOBE_DEFINE_ARITHMETIC_OPS(Baz) --- 27,46 ---- enum Foo ! { ! foo_4 = 1 << 2, ! foo_8 = 1 << 3 ! }; enum Bar ! { ! bar_4 = 1 << 2, ! bar_8 = 1 << 3 ! }; enum Baz ! { ! baz_4 = 1 << 2, ! baz_8 = 1 << 3 ! }; ADOBE_DEFINE_ARITHMETIC_OPS(Baz) *************** *** 49,66 **** int main() ! { ! Foo a(foo_4); ! Bar b(bar_8); ! Foo c(a + b); // error! a and b are different enum types, so result is integral ! Baz d(baz_4); ! Baz e(baz_8); ! Baz f(d + e); // Ok, ADOBE_DEFINE_ARITHMETIC_OPS(Baz) is defined, so d + e has type Baz ! BOOST_TEST(c); ! BOOST_TEST(f); ! return boost::report_errors(); ! } // end_of_example --- 49,66 ---- int main() ! { ! Foo a(foo_4); ! Bar b(bar_8); ! Foo c(a + b); // error! a and b are different enum types, so result is integral ! Baz d(baz_4); ! Baz e(baz_8); ! Baz f(d + e); // Ok, ADOBE_DEFINE_ARITHMETIC_OPS(Baz) is defined, so d + e has type Baz ! BOOST_TEST(c); ! BOOST_TEST(f); ! return boost::report_errors(); ! } // end_of_example Index: enum_ops_example.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples/enum_ops_example.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** enum_ops_example.cpp 8 Sep 2005 15:51:11 -0000 1.1 --- enum_ops_example.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2001 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2001 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 27,49 **** enum Foo ! { ! foo_4 = 1 << 2, ! foo_8 = 1 << 3 ! }; ADOBE_DEFINE_BITSET_OPS(Foo) int main() ! { ! Foo a(foo_4); ! Foo b(foo_8); ! Foo c(a | b); ! BOOST_TEST(a == 4L); ! BOOST_TEST(b == 8L); ! BOOST_TEST(c == 12L); ! return boost::report_errors(); ! } // end_of_example --- 27,49 ---- enum Foo ! { ! foo_4 = 1 << 2, ! foo_8 = 1 << 3 ! }; ADOBE_DEFINE_BITSET_OPS(Foo) int main() ! { ! Foo a(foo_4); ! Foo b(foo_8); ! Foo c(a | b); ! BOOST_TEST(a == 4L); ! BOOST_TEST(b == 8L); ! BOOST_TEST(c == 12L); ! return boost::report_errors(); ! } // end_of_example Index: specialization.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples/specialization.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** specialization.cpp 28 Apr 2005 05:33:26 -0000 1.1 --- specialization.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 38,42 **** // ... }; ! } // my_namespace --- 38,42 ---- // ... }; ! } // my_namespace *************** *** 46,50 **** my_namespace::my_iterator std::find(my_namespace::my_iterator, my_namespace::my_iterator) { ! // do special find } --- 46,50 ---- my_namespace::my_iterator std::find(my_namespace::my_iterator, my_namespace::my_iterator) { ! // do special find } *************** *** 54,65 **** struct ptr_traits<my_namespace::my_class> { ! typedef my_namespace::my_class element_type; ! typedef element_type* pointer_type; ! typedef const element_type* const_pointer_type ! ! template <class U> struct rebind { typedef adobe::ptr_traits<U> other; }; ! enum { is_array = false }; ! ! static void delete_ptr(pointer_type x) throw() { delete x; } }; --- 54,65 ---- struct ptr_traits<my_namespace::my_class> { ! typedef my_namespace::my_class element_type; ! typedef element_type* pointer_type; ! typedef const element_type* const_pointer_type ! ! template <class U> struct rebind { typedef adobe::ptr_traits<U> other; }; ! enum { is_array = false }; ! ! static void delete_ptr(pointer_type x) throw() { delete x; } }; Index: namespace.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples/namespace.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** namespace.cpp 28 Apr 2005 05:33:26 -0000 1.1 --- namespace.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 31,37 **** // Correct usage of namespace qualifiers ! adobe::forest<int> my_forest; ! ! adobe::find(my_forest, 5); } --- 31,37 ---- // Correct usage of namespace qualifiers ! adobe::forest<int> my_forest; ! ! adobe::find(my_forest, 5); } *************** *** 41,49 **** // Accepted usage of namespace qualifiers ! namespace asl = adobe; ! ! asl::forest<int> my_forest; ! ! asl::find(my_forest, 5); } --- 41,49 ---- // Accepted usage of namespace qualifiers ! namespace asl = adobe; ! ! asl::forest<int> my_forest; ! ! asl::find(my_forest, 5); } *************** *** 53,62 **** // This works - but is not recommended ! using namespace std; ! ! bool my_predicate(int); ! adobe::forest<int> my_forest; ! ! find_if(my_forest.begin(), my_forest.end(), &my_predicate); // calls std::find_if() } --- 53,62 ---- // This works - but is not recommended ! using namespace std; ! ! bool my_predicate(int); ! adobe::forest<int> my_forest; ! ! find_if(my_forest.begin(), my_forest.end(), &my_predicate); // calls std::find_if() } Index: namespace_fail.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/examples/namespace_fail.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** namespace_fail.cpp 28 Apr 2005 05:33:26 -0000 1.1 --- namespace_fail.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2004 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 32,41 **** // This results in an ambiguity and won't compile ! using namespace adobe; ! ! bool my_predicate(int); ! std::vector<int> my_vector; ! ! find_if(my_vector.begin(), my_vector.end(), &my_predicate); // adobe or std? } --- 32,41 ---- // This results in an ambiguity and won't compile ! using namespace adobe; ! ! bool my_predicate(int); ! std::vector<int> my_vector; ! ! find_if(my_vector.begin(), my_vector.end(), &my_predicate); // adobe or std? } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:22
|
Update of /cvsroot/adobe-source/sandbox/adobe-source In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755 Modified Files: Jamfile.v2 project-root.jam read_me.txt release_notes.txt Added Files: manifest.jam Log Message: asl 1.0.13 --- NEW FILE: manifest.jam --- import type ; import targets ; import path ; type.register MANIFEST : manifest ; type.register MANIFESTTMPL : manifesttmpl ; import generators ; generators.register-standard manifest.manifest : MANIFESTTMPL : MANIFEST ; rule manifest ( target : source : property-set * ) { if <toolset-msvc:version>8.0 in $(property-set) { if <variant>debug in $(property-set) { .suffix = .msvc8.debug.manifest ; } else { .suffix = .msvc8.release.manifest ; } } else { if <toolset-msvc:version>7.1 in $(property-set) { .suffix = .msvc7.manifest ; } } local srcpath = [ MATCH "^<p(.*)>$" : $(source:G) ] ; local dstpath = [ MATCH "^<p(.*)>$" : $(target:G) ] ; .srcfile = [ path.native "$(srcpath)/$(source:D)/$(source:B)$(.suffix)" ] ; .dstfile = [ path.native "$(dstpath)/$(target:D)$(target:B).manifest" ] ; } actions manifest { copy /Y "$(.srcfile)" "$(.dstfile)" } Index: Jamfile.v2 =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/Jamfile.v2,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Jamfile.v2 6 Jan 2006 18:02:35 -0000 1.15 --- Jamfile.v2 3 Feb 2006 18:33:35 -0000 1.16 *************** *** 24,35 **** project top : requirements ! <threading>multi ! <include>third_party/boost_tp/boost ! <toolset>msvc:<define>_SCL_SECURE_NO_DEPRECATE ! <toolset>darwin:<cxxflags>"-Werror" ! <toolset>gcc,<variant>debug:<cxxflags>"-Werror" ! $(ARCH) : default-build ! <link>static : build-dir $(BUILD_DIR) --- 24,35 ---- project top : requirements ! <threading>multi ! <include>third_party/boost_tp/boost ! <toolset>msvc:<define>_SCL_SECURE_NO_DEPRECATE ! <toolset>darwin:<cxxflags>"-Werror" ! <toolset>gcc,<variant>debug:<cxxflags>"-Werror" ! $(ARCH) : default-build ! <link>static : build-dir $(BUILD_DIR) *************** *** 44,71 **** case MACOSX : { ! alias boost_filesystem : /boost/filesystem/<arch>fat ; ! alias boost_thread : /boost/thread/<arch>fat ; ! alias boost_signals : /boost/signals/<arch>fat ; } case * : { ! alias boost_filesystem : /boost/filesystem ; ! alias boost_thread : /boost/thread ; ! alias boost_signals : /boost/signals ; } } ! alias asl : adobe//asl ; ! alias asl_dev : adobe//asl_dev ; ! alias adam_smoke : adobe/test/adam_smoke : <variant>debug ; ! alias adam_tutorial : adobe/test/adam_tutorial ; ! alias eve_smoke : adobe/test/eve_smoke ; ! alias forest_smoke : adobe/test/forest_smoke ; ! alias gil : adobe/test/gil ; ! alias md5 : adobe/test/md5 ; ! alias sha : adobe/test/sha ; ! alias xstr_test : adobe/test/xstr_test ; ! alias zuidgen : adobe/test/zuidgen ; --- 44,72 ---- case MACOSX : { ! alias boost_filesystem : /boost/filesystem/<arch>fat ; ! alias boost_thread : /boost/thread/<arch>fat ; ! alias boost_signals : /boost/signals/<arch>fat ; } case * : { ! alias boost_filesystem : /boost/filesystem ; ! alias boost_thread : /boost/thread ; ! alias boost_signals : /boost/signals ; } } ! alias asl : adobe//asl ; ! alias asl_dev : adobe//asl_dev ; ! alias adam_smoke : adobe/test/adam_smoke : <variant>debug ; ! alias adam_tutorial : adobe/test/adam_tutorial ; ! alias cmath : adobe/test/cmath ; ! alias eve_smoke : adobe/test/eve_smoke ; ! alias forest_smoke : adobe/test/forest_smoke ; ! alias gil : adobe/test/gil ; ! alias md5 : adobe/test/md5 ; ! alias sha : adobe/test/sha ; ! alias xstr_test : adobe/test/xstr_test ; ! alias zuidgen : adobe/test/zuidgen ; Index: read_me.txt =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/read_me.txt,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** read_me.txt 6 Jan 2006 18:02:35 -0000 1.20 --- read_me.txt 3 Feb 2006 18:33:35 -0000 1.21 *************** *** 1,3 **** ! Build Instructions 20060105 --- 1,3 ---- ! Build Instructions 20060202 *************** *** 183,190 **** Build fails to run? Check: ! - Boost is in its proper place ! - Boost was properly patched ! - Permissions allow execution of the build scripts ! - Line endings of all files are correct for your platform --- 183,190 ---- Build fails to run? Check: ! - Boost is in its proper place ! - Boost was properly patched ! - Permissions allow execution of the build scripts ! - Line endings of all files are correct for your platform *************** *** 238,242 **** ~/adobe-source/third_party/boost_tp/boost/bin.v2/ (*nix) or ! C:\adobe-source\third_party\boost_tp\boost\bin.v2\ (Windows) - It is possible to create an IDE project for MSVC 7.1 (and probably --- 238,242 ---- ~/adobe-source/third_party/boost_tp/boost/bin.v2/ (*nix) or ! C:\adobe-source\third_party\boost_tp\boost\bin.v2\ (Windows) - It is possible to create an IDE project for MSVC 7.1 (and probably *************** *** 278,290 **** installation options when installing XCode) ! By default the ASL (through BBv2) is set up to build universal binaries ! and libs. In order to disable universal binary building within ASL, open ! up ~/adobe-source/Jamfile.v2 and comment out (or delete) the MACOSX case within the first switch block in the file (dealing with the ARCH and ALIAS_ARCH variables). ! When compiling Adobe Begin note that if you disable universal binary ! building you will have to update the ASL library paths within the XCode ! project to point to the non-universal versions. --- 278,294 ---- installation options when installing XCode) ! By default ASL (via BBv2) is set up to build Universal Binaries. In ! order to disable universal binary building within ASL, open ! ~/adobe-source/Jamfile.v2 and comment out (or delete) the MACOSX case within the first switch block in the file (dealing with the ARCH and ALIAS_ARCH variables). ! To disable building Universal Binaries with the XCode IDE projects, open ! ~/adobe-source/ide_projects/darwin/adobe_all.xcconfig and edit the line ! "ARCHS = i386 ppc" to read just "ARCHS = ppc". Reloading the XCode IDE ! projects at that time will cause Universal Binary support to be dropped, ! building only PowerPC versions of the binaries. Alternatively, you can ! drop "ppc" if you are only interested in building MacTel versions of the ! binaries. Index: project-root.jam =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/project-root.jam,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** project-root.jam 6 Jan 2006 18:02:35 -0000 1.4 --- project-root.jam 3 Feb 2006 18:33:35 -0000 1.5 *************** *** 2,5 **** --- 2,7 ---- path-constant BUILD_DIR : ./bin.v2 ; + import manifest ; + use-project /boost : third_party/boost_tp/boost ; use-project /adobe : adobe/ ; Index: release_notes.txt =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/release_notes.txt,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** release_notes.txt 6 Jan 2006 18:02:35 -0000 1.10 --- release_notes.txt 3 Feb 2006 18:33:35 -0000 1.11 *************** *** 1,3 **** ! Release Notes 20060105 --- 1,3 ---- ! Release Notes 20060202 *************** *** 6,9 **** --- 6,87 ---- ================ + 2006/02/02 + Adam: + - Added adobe::basic_sheet_t, a class used to manage dialog + state-related values, a subset of features of the full Adam + - Added support for "weak" relations. + - Better error reporting for over-contraint cases. + - Unlinked cells are once again allowed to relate to each other when + figuring out whether or not to pin a new value on the model. + - Extended information at: + <http://opensource.adobe.com/twiki/bin/view/AdobeSource/AdamEvolution> + ASL: + - Tabs have been replaced with 4 spaces in the entire ASL code + repository. This includes everything but Doxygen-generated html files + and IDE project files. + base: + - Added a nearest_cast<> from Mark Ruzon. Used it as an excuse to + clean-up the rounding code in ASL to conform with C99 round() and added + "path stability" to Adam solver. + - adobe/cmath.hpp has been augmented to include support for more + C99/TR1 extensions + - Added modal_dialog_interface and adobe::handle_dialog, a + self-contained API used to manage a modal dialog instance, leveraging + Adam, Eve and the ui_core. + - More fixes for stream error reporting has been changed; you now + supply a callback to fetch a line from the stream and the stream + formatter will use the callback before formatting the stream error + Begin: + - Fixing code from Eve parser rework and stripping of widget + serialization and overlay from non-debug builds. + - More examples added to demonstrate various Adam/Eve features + - Much work has been done to improve manifest support for Win32. + Manifest generation has been added MSVC 8 projects. bjam was augmented + with a rule that copies the appropriate manifest file into place + - Reworked the factory_token and setting the root widget display + element in the eve_client_holder, which allows for us to extract the + platform-specific root window view out of it and manipulate it (e.g., + run it under a modal loop). + Boost: + - Unpatched msvc.jam. Use conditional based on msvc-toolset:version + in Begin's Jamfile.v2 instead. Fixes merged 8.0/7.1 settings bug + - Please repatch your Boost distribution + Eve: + - Eve now supports a minimum height and width for containers; Both + the Mac and Win32 ui_core implementations have been updated to leverage + this + - Hide/show updates + GIL: + - Many bug fixes and other improvements + - Updates to the design guide. Added tutorial. + IDE: + - Moved iomanip files from widgets to asl_dev (Mac and Win32) + - MSVC project now has a build directory and copy sheets and + glossary from sources (by Thomas Witt) + Widgets Library: + - Began fixing up static text rect size on win32 + - Fixed a Mac bug where a widget's static disabled text's bounds and + position were incorrect when shown at the first instance + - Resolved the bug where the combo box drop down would take up the + entire screen if there were enough elements. It turned out that this + behavior was being explicitly set (!); now we will show enough room for + all of the elements up to a maximum of 10 (at which point you will get a + scrollbar). This still doesn't verify that the specified size can fit on + the screen (e.g.: Windows PocketPC might have trouble), and uses a fixed + value. (by Ralph Thomas) + - The Mac ui_core implementation has been completely reworked, + removing inheritance and cleaning up general code flow. Consequently the + essentials() and widget serialization hooks have been stripped and + stubbed + - This commit partially addresses the Win32 nested group issue. + There is more information on the fix in the comments of + ui_core_implementation.cpp. Inner groups labels are struck through by + the group line; there may be another message that we can catch to fix + this... dialogs now look better, but still not perfect (by Ralph Thomas) + - Fix Win32 edit_number crashes when label is empty. (by Thomas + Witt) + - Mac ui_core implementation caches widget metrics now, speeding up + metrics-related operations (by Ralph Thomas) + 2006/01/05 - Added the Generic Image Library (GIL). This library allows for |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:22
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/bin Modified Files: asl_net_setup.bat asl_net_setup.sh build.bat build.sh install.sh verify.sh Log Message: asl 1.0.13 Index: build.bat =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/build.bat,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** build.bat 2 Dec 2005 02:59:11 -0000 1.6 --- build.bat 3 Feb 2006 18:33:35 -0000 1.7 *************** *** 9,27 **** if EXIST "%ProgramFiles%\Microsoft Visual Studio .NET 2003\VC7\" ( ! set BOOST_JAM_TOOLSET_ROOT=%ProgramFiles%\Microsoft Visual Studio .NET 2003\VC7\ ! set VC71_ROOT=%BOOST_JAM_TOOLSET_ROOT% ) if "_%BOOST_JAM_TOOLSET_ROOT%_" == "__" ( ! echo ### ! echo ### Your installation of MSVC is not in a default location. ! echo ### You must set environment variable "BOOST_JAM_TOOLSET_ROOT" before you can continue. ! echo ### You can either do this by typing at the command line: ! echo ### "set BOOST_JAM_TOOLSET_ROOT=C:\Directory\Path\To\VC71\" ! echo ### or by setting it as an environment variable in your Windows ! echo ### system settings control panel. ! echo ### Don't forget the final backslash! ! echo ### ! goto :Error ) --- 9,27 ---- if EXIST "%ProgramFiles%\Microsoft Visual Studio .NET 2003\VC7\" ( ! set BOOST_JAM_TOOLSET_ROOT=%ProgramFiles%\Microsoft Visual Studio .NET 2003\VC7\ ! set VC71_ROOT=%BOOST_JAM_TOOLSET_ROOT% ) if "_%BOOST_JAM_TOOLSET_ROOT%_" == "__" ( ! echo ### ! echo ### Your installation of MSVC is not in a default location. ! echo ### You must set environment variable "BOOST_JAM_TOOLSET_ROOT" before you can continue. ! echo ### You can either do this by typing at the command line: ! echo ### "set BOOST_JAM_TOOLSET_ROOT=C:\Directory\Path\To\VC71\" ! echo ### or by setting it as an environment variable in your Windows ! echo ### system settings control panel. ! echo ### Don't forget the final backslash! ! echo ### ! goto :Error ) *************** *** 34,38 **** if EXIST "%BOOST_JAM_TOOLSET_ROOT%bin\VCVARS32.BAT" ( ! call "%BOOST_JAM_TOOLSET_ROOT%bin\VCVARS32.BAT" ) --- 34,38 ---- if EXIST "%BOOST_JAM_TOOLSET_ROOT%bin\VCVARS32.BAT" ( ! call "%BOOST_JAM_TOOLSET_ROOT%bin\VCVARS32.BAT" ) *************** *** 41,45 **** if EXIST "bjam.exe" ( ! DEL bjam.exe ) --- 41,45 ---- if EXIST "bjam.exe" ( ! DEL bjam.exe ) *************** *** 56,61 **** if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) --- 56,61 ---- if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) *************** *** 64,73 **** POPD if "_%HOME%_" == "__" ( ! set HOME=C:\TEMP\adobe-source ) if NOT EXIST "%HOME%" ( ! MkDir %HOME%\ ) --- 64,75 ---- POPD + set TEMP_HOME=C:\TEMP\adobe-source + if "_%HOME%_" == "__" ( ! set HOME=%TEMP_HOME% ) if NOT EXIST "%HOME%" ( ! MkDir %HOME%\ ) *************** *** 75,84 **** if NOT EXIST "%HOME%\user-config.jam" ( ! echo import msvc-config ; > %HOME%\user-config.jam ) if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) --- 77,90 ---- if NOT EXIST "%HOME%\user-config.jam" ( ! echo import msvc-config ; > %HOME%\user-config.jam ! ) ! ! if "_%HOME%_" == "_%TEMP_HOME%_" ( ! echo import msvc-config ; > %HOME%\user-config.jam ) if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) *************** *** 90,95 **** if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) --- 96,101 ---- if ERRORLEVEL 1 ( ! echo ### Error : %ERRORLEVEL% ! EXIT /B %ERRORLEVEL% ) Index: install.sh =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/install.sh,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** install.sh 20 Jul 2005 21:22:51 -0000 1.2 --- install.sh 3 Feb 2006 18:33:35 -0000 1.3 *************** *** 33,39 **** if test_path cmd ; then ! echo_run $BJAM"/build.bat" else ! echo_run $BJAM"/build.sh" fi --- 33,39 ---- if test_path cmd ; then ! echo_run $BJAM"/build.bat" else ! echo_run $BJAM"/build.sh" fi Index: verify.sh =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/verify.sh,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** verify.sh 21 Sep 2005 18:39:36 -0000 1.4 --- verify.sh 3 Feb 2006 18:33:35 -0000 1.5 *************** *** 8,26 **** if [ "$1" != "" ]; then ! MODE="$1" fi if [ "$MODE" == "debug" ]; then ! BOOSTLIBEXT="-d" else ! BOOSTLIBEXT="" fi LIBRARY_SET=(\ ! third_party/boost_tp/boost/bin.v2/libs/filesystem/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_filesystem-mt"$BOOSTLIBEXT"-1_33.a \ ! third_party/boost_tp/boost/bin.v2/libs/signals/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_signals-mt"$BOOSTLIBEXT"-1_33.a \ ! third_party/boost_tp/boost/bin.v2/libs/thread/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_thread-mt"$BOOSTLIBEXT"-1_33.a \ ! bin.v2/adobe/build/darwin/$MODE/arch-fat/asl-dev/link-static/threading-multi/libasl_dev.a \ ! bin.v2/adobe/future/widgets/darwin/$MODE/arch-fat/asl-dev/link-static/threading-multi/user-interface-gui/libadobe_widgets.a \ ) --- 8,26 ---- if [ "$1" != "" ]; then ! MODE="$1" fi if [ "$MODE" == "debug" ]; then ! BOOSTLIBEXT="-d" else ! BOOSTLIBEXT="" fi LIBRARY_SET=(\ ! third_party/boost_tp/boost/bin.v2/libs/filesystem/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_filesystem-mt"$BOOSTLIBEXT"-1_33.a \ ! third_party/boost_tp/boost/bin.v2/libs/signals/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_signals-mt"$BOOSTLIBEXT"-1_33.a \ ! third_party/boost_tp/boost/bin.v2/libs/thread/build/darwin/$MODE/arch-fat/link-static/threading-multi/libboost_thread-mt"$BOOSTLIBEXT"-1_33.a \ ! bin.v2/adobe/build/darwin/$MODE/arch-fat/asl-dev/link-static/threading-multi/libasl_dev.a \ ! bin.v2/adobe/future/widgets/darwin/$MODE/arch-fat/asl-dev/link-static/threading-multi/user-interface-gui/libadobe_widgets.a \ ) *************** *** 30,59 **** while [ $COUNTER != $SET_COUNT ]; do ! CURRENT_LIB="${LIBRARY_SET[$COUNTER]}" ! if [ ! -e $CURRENT_LIB ]; then ! BASENAME=`basename $CURRENT_LIB` ! DIRNAME=`dirname $CURRENT_LIB` ! if [ `uname` == "Darwin" ]; then ! osascript -e 'tell application "Finder"' -e 'activate' -e 'beep' -e "display alert \"Cannot find required file:\\n\\n\\t$BASENAME\\n\\nfor the $MODE build.\\n\\nPlease check the read_me.txt file in the ASL distribution for information on how to build this library.\" message \"Looked in directory \\\"$DIRNAME\\\"\" buttons \"OK\" default button \"OK\" as warning" -e "end tell" ! else ! echo "Cannot find required library file \"$BASENAME\" for the $MODE build. Please check the read_me.txt file in the ASL distribution for information on how to build this library." ! fi ! exit 1 ! # else ! # echo "Found \"`basename $CURRENT_LIB`\"" ! fi ! let COUNTER=COUNTER+1 done --- 30,59 ---- while [ $COUNTER != $SET_COUNT ]; do ! CURRENT_LIB="${LIBRARY_SET[$COUNTER]}" ! if [ ! -e $CURRENT_LIB ]; then ! BASENAME=`basename $CURRENT_LIB` ! DIRNAME=`dirname $CURRENT_LIB` ! if [ `uname` == "Darwin" ]; then ! osascript -e 'tell application "Finder"' -e 'activate' -e 'beep' -e "display alert \"Cannot find required file:\\n\\n\\t$BASENAME\\n\\nfor the $MODE build.\\n\\nPlease check the read_me.txt file in the ASL distribution for information on how to build this library.\" message \"Looked in directory \\\"$DIRNAME\\\"\" buttons \"OK\" default button \"OK\" as warning" -e "end tell" ! else ! echo "Cannot find required library file \"$BASENAME\" for the $MODE build. Please check the read_me.txt file in the ASL distribution for information on how to build this library." ! fi ! exit 1 ! # else ! # echo "Found \"`basename $CURRENT_LIB`\"" ! fi ! let COUNTER=COUNTER+1 done Index: build.sh =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/build.sh,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** build.sh 7 Nov 2005 18:08:53 -0000 1.4 --- build.sh 3 Feb 2006 18:33:35 -0000 1.5 *************** *** 22,30 **** # Assuming the client only needs to run this once, we always build bjam if [ -e bjam ]; then ! if test_path cmd ; then ! echo_run rm bjam.exe ! else ! echo_run rm bjam ! fi fi --- 22,30 ---- # Assuming the client only needs to run this once, we always build bjam if [ -e bjam ]; then ! if test_path cmd ; then ! echo_run rm bjam.exe ! else ! echo_run rm bjam ! fi fi *************** *** 33,56 **** cd ../../ if [ "$HOME" == "" ]; then ! HOME="/tmp/adobe-source" fi if [ ! -d "$HOME" ]; then ! echo_run mkdir -p "$HOME" fi ! if [ ! -e "$HOME/user-config.jam" ]; then ! if [ "`uname`" == "Darwin" ]; then ! echo "import toolset : using ; using darwin ;" > "$HOME/user-config.jam" ! else ! if [ -d "$PROGRAMFILES/Microsoft Visual Studio .NET 2003/" ]; then ! echo "import msvc-config ; import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! elif [ -d "$PROGRAMFILES/Microsoft Visual Studio 8/" ]; then ! echo "import msvc-config ; import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! else ! echo "import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! fi ! fi fi --- 33,58 ---- cd ../../ + TEMP_HOME="/tmp/adobe-source" + if [ "$HOME" == "" ]; then ! HOME=$TEMP_HOME fi if [ ! -d "$HOME" ]; then ! echo_run mkdir -p "$HOME" fi ! if [ ! -e "$HOME/user-config.jam" -o "$HOME" == "$TEMP_HOME"]; then ! if [ "`uname`" == "Darwin" ]; then ! echo "import toolset : using ; using darwin ;" > "$HOME/user-config.jam" ! else ! if [ -d "$PROGRAMFILES/Microsoft Visual Studio .NET 2003/" ]; then ! echo "import msvc-config ; import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! elif [ -d "$PROGRAMFILES/Microsoft Visual Studio 8/" ]; then ! echo "import msvc-config ; import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! else ! echo "import toolset : using ; using gcc ;" > "$HOME/user-config.jam" ! fi ! fi fi *************** *** 58,68 **** if [ "$1" != "" ]; then ! MODE=$1 fi if test_path cmd ; then ! echo_run adobe/bin/bjam msvc gcc $MODE else ! echo_run adobe/bin/bjam $MODE fi --- 60,70 ---- if [ "$1" != "" ]; then ! MODE=$1 fi if test_path cmd ; then ! echo_run adobe/bin/bjam msvc gcc $MODE else ! echo_run adobe/bin/bjam $MODE fi Index: asl_net_setup.bat =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/asl_net_setup.bat,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** asl_net_setup.bat 6 Jan 2006 18:02:35 -0000 1.6 --- asl_net_setup.bat 3 Feb 2006 18:33:35 -0000 1.7 *************** *** 1,5 **** @ECHO OFF ! set ASL_DISTRO_NAME=asl_1.0.12.zip set ASL_DIR_NAME=adobe-source set ASL_DISTRO_HOST=easynews.dl.sourceforge.net --- 1,5 ---- @ECHO OFF ! set ASL_DISTRO_NAME=asl_1.0.13.zip set ASL_DIR_NAME=adobe-source set ASL_DISTRO_HOST=easynews.dl.sourceforge.net *************** *** 15,74 **** if NOT EXIST %UNZIP_DISTRO_NAME% ( ! echo Getting unzip executable... ! echo cd pub/unix/archiving/info-zip/WIN32 > cmds.txt ! echo bin >> cmds.txt ! echo get %UNZIP_DISTRO_NAME% >> cmds.txt ! echo bye >> cmds.txt ! ftp -v -s:cmds.txt -A sunsite.icm.edu.pl ! del cmds.txt ) if NOT EXIST %CURL_DISTRO_NAME% ( ! echo Getting curl distribution... ! echo cd pub/www/utilities/curl > cmds.txt ! echo bin >> cmds.txt ! echo get %CURL_DISTRO_NAME% >> cmds.txt ! echo bye >> cmds.txt ! ftp -v -s:cmds.txt -A ftp.sunet.se ! del cmds.txt ) if NOT EXIST %UNZIP_EXE_NAME% ( ! echo Setting up unzip... ! mkdir unzip ! move unz552xN.exe unzip ! PUSHD unzip ! unz552xN.exe ! POPD ) if NOT EXIST %CURL_EXE_NAME% ( ! echo Extracting curl... ! %UNZIP_EXE_NAME% %CURL_DISTRO_NAME% ) if NOT "_%1%_" == "__" ( ! set ASL_DISTRO_HOST=%1% ) if NOT EXIST %ASL_DISTRO_NAME% ( ! echo Getting ASL distribution... ! %CURL_EXE_NAME% http://%ASL_DISTRO_HOST%/sourceforge/adobe-source/%ASL_DISTRO_NAME% -o %ASL_DISTRO_NAME% ) if NOT EXIST %BOOST_DISTRO_NAME% ( ! echo Getting Boost distribution... ! %CURL_EXE_NAME% http://easynews.dl.sourceforge.net/sourceforge/boost/%BOOST_DISTRO_NAME% -o %BOOST_DISTRO_NAME% ) --- 15,74 ---- if NOT EXIST %UNZIP_DISTRO_NAME% ( ! echo Getting unzip executable... ! echo cd pub/unix/archiving/info-zip/WIN32 > cmds.txt ! echo bin >> cmds.txt ! echo get %UNZIP_DISTRO_NAME% >> cmds.txt ! echo bye >> cmds.txt ! ftp -v -s:cmds.txt -A sunsite.icm.edu.pl ! del cmds.txt ) if NOT EXIST %CURL_DISTRO_NAME% ( ! echo Getting curl distribution... ! echo cd pub/www/utilities/curl > cmds.txt ! echo bin >> cmds.txt ! echo get %CURL_DISTRO_NAME% >> cmds.txt ! echo bye >> cmds.txt ! ftp -v -s:cmds.txt -A ftp.sunet.se ! del cmds.txt ) if NOT EXIST %UNZIP_EXE_NAME% ( ! echo Setting up unzip... ! mkdir unzip ! move unz552xN.exe unzip ! PUSHD unzip ! unz552xN.exe ! POPD ) if NOT EXIST %CURL_EXE_NAME% ( ! echo Extracting curl... ! %UNZIP_EXE_NAME% %CURL_DISTRO_NAME% ) if NOT "_%1%_" == "__" ( ! set ASL_DISTRO_HOST=%1% ) if NOT EXIST %ASL_DISTRO_NAME% ( ! echo Getting ASL distribution... ! %CURL_EXE_NAME% http://%ASL_DISTRO_HOST%/sourceforge/adobe-source/%ASL_DISTRO_NAME% -o %ASL_DISTRO_NAME% ) if NOT EXIST %BOOST_DISTRO_NAME% ( ! echo Getting Boost distribution... ! %CURL_EXE_NAME% http://easynews.dl.sourceforge.net/sourceforge/boost/%BOOST_DISTRO_NAME% -o %BOOST_DISTRO_NAME% ) *************** *** 76,107 **** if NOT EXIST %PATCH_DISTRO_NAME% ( ! echo Getting Win32 patch distribution... ! %CURL_EXE_NAME% http://easynews.dl.sourceforge.net/sourceforge/gnuwin32/%PATCH_DISTRO_NAME% -o %PATCH_DISTRO_NAME% ) if NOT EXIST %PATCH_EXE_NAME% ( ! echo Extracting patch... ! copy %PATCH_DISTRO_NAME% gnuwin32\ ! PUSHD gnuwin32\ ! ..\%UNZIP_EXE_NAME% %PATCH_DISTRO_NAME% > nul ! POPD ) if NOT EXIST %ASL_DIR_NAME% ( ! echo Extracting ASL distribution... ! %UNZIP_EXE_NAME% %ASL_DISTRO_NAME% > nul ) if NOT EXIST adobe-source\third_party\boost_tp\%BOOST_DIR_NAME% ( ! echo Setting up destination Boost directory, which could take a while... ! %UNZIP_EXE_NAME% %BOOST_DISTRO_NAME% > nul ! move %BOOST_DIR_NAME% adobe-source\third_party\boost_tp ) if NOT EXIST adobe-source\third_party\boost_tp\boost ( ! echo Setting up source Boost directory, which could take a while... ! PUSHD adobe-source\third_party\boost_tp ! xcopy %BOOST_DIR_NAME% boost /S /E /I /Y > nul ! POPD ) --- 76,107 ---- if NOT EXIST %PATCH_DISTRO_NAME% ( ! echo Getting Win32 patch distribution... ! %CURL_EXE_NAME% http://easynews.dl.sourceforge.net/sourceforge/gnuwin32/%PATCH_DISTRO_NAME% -o %PATCH_DISTRO_NAME% ) if NOT EXIST %PATCH_EXE_NAME% ( ! echo Extracting patch... ! copy %PATCH_DISTRO_NAME% gnuwin32\ ! PUSHD gnuwin32\ ! ..\%UNZIP_EXE_NAME% %PATCH_DISTRO_NAME% > nul ! POPD ) if NOT EXIST %ASL_DIR_NAME% ( ! echo Extracting ASL distribution... ! %UNZIP_EXE_NAME% %ASL_DISTRO_NAME% > nul ) if NOT EXIST adobe-source\third_party\boost_tp\%BOOST_DIR_NAME% ( ! echo Setting up destination Boost directory, which could take a while... ! %UNZIP_EXE_NAME% %BOOST_DISTRO_NAME% > nul ! move %BOOST_DIR_NAME% adobe-source\third_party\boost_tp ) if NOT EXIST adobe-source\third_party\boost_tp\boost ( ! echo Setting up source Boost directory, which could take a while... ! PUSHD adobe-source\third_party\boost_tp ! xcopy %BOOST_DIR_NAME% boost /S /E /I /Y > nul ! POPD ) Index: asl_net_setup.sh =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/bin/asl_net_setup.sh,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** asl_net_setup.sh 6 Jan 2006 18:02:35 -0000 1.6 --- asl_net_setup.sh 3 Feb 2006 18:33:35 -0000 1.7 *************** *** 1,5 **** #!/bin/bash ! ASL_DISTRO_NAME=asl_1.0.12.tgz ASL_DISTRO_SITE=easynews.dl.sourceforge.net BOOST_NAME=boost_1_33_1 --- 1,5 ---- #!/bin/bash ! ASL_DISTRO_NAME=asl_1.0.13.tgz ASL_DISTRO_SITE=easynews.dl.sourceforge.net BOOST_NAME=boost_1_33_1 *************** *** 31,57 **** if [ "$1" != "" ]; then ! ASL_DISTRO_SITE="$1" fi if [ ! -e $ASL_DISTRO_NAME ]; then ! echo_run curl http://$ASL_DISTRO_SITE/sourceforge/adobe-source/$ASL_DISTRO_NAME -o $ASL_DISTRO_NAME fi if [ ! -e $BOOST_DISTRO_NAME ]; then ! echo_run curl http://easynews.dl.sourceforge.net/sourceforge/boost/$BOOST_DISTRO_NAME -o $BOOST_DISTRO_NAME fi if [ ! -d adobe-source ]; then ! echo_run tar -xzf $ASL_DISTRO_NAME fi if [ ! -d adobe-source/third_party/boost_tp/$BOOST_NAME ]; then ! echo_run tar -xzf $BOOST_DISTRO_NAME ! echo_run mv $BOOST_NAME adobe-source/third_party/boost_tp/ fi if [ ! -d adobe-source/third_party/boost_tp/boost ]; then ! echo_run tar -xzf $BOOST_DISTRO_NAME ! echo_run mv $BOOST_NAME adobe-source/third_party/boost_tp/boost fi --- 31,57 ---- if [ "$1" != "" ]; then ! ASL_DISTRO_SITE="$1" fi if [ ! -e $ASL_DISTRO_NAME ]; then ! echo_run curl http://$ASL_DISTRO_SITE/sourceforge/adobe-source/$ASL_DISTRO_NAME -o $ASL_DISTRO_NAME fi if [ ! -e $BOOST_DISTRO_NAME ]; then ! echo_run curl http://easynews.dl.sourceforge.net/sourceforge/boost/$BOOST_DISTRO_NAME -o $BOOST_DISTRO_NAME fi if [ ! -d adobe-source ]; then ! echo_run tar -xzf $ASL_DISTRO_NAME fi if [ ! -d adobe-source/third_party/boost_tp/$BOOST_NAME ]; then ! echo_run tar -xzf $BOOST_DISTRO_NAME ! echo_run mv $BOOST_NAME adobe-source/third_party/boost_tp/ fi if [ ! -d adobe-source/third_party/boost_tp/boost ]; then ! echo_run tar -xzf $BOOST_DISTRO_NAME ! echo_run mv $BOOST_NAME adobe-source/third_party/boost_tp/boost fi |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:22
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/source Modified Files: assemblage.cpp cmd_system.cpp iomanip.cpp iomanip_asl_cel.cpp iomanip_pdf.cpp iomanip_xml.cpp menu_system.cpp modal_dialog_interface.cpp Log Message: asl 1.0.13 Index: cmd_system.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source/cmd_system.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** cmd_system.cpp 6 Jan 2006 18:02:57 -0000 1.2 --- cmd_system.cpp 3 Feb 2006 18:33:36 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 22,63 **** struct command_system_t::implementation_t { ! struct command_entry_t ! { ! typedef boost::signal<void (bool)> enable_callback_list_t; ! command_entry_t() : ! enabled_m(false) ! { } ! command_entry_t(const command_entry_t& rhs) : ! enabled_m(rhs.enabled_m) ! { } ! command_entry_t& operator = (const command_entry_t& rhs) ! { ! enabled_m = rhs.enabled_m; ! return *this; ! } ! command_proc_t proc_m; ! bool enabled_m; ! enable_callback_list_t enabled_callback_m; ! }; ! typedef std::map<adobe::name_t, command_entry_t> command_map_t; ! void insert_command(adobe::name_t name, const command_proc_t& proc); ! void remove_command(adobe::name_t name); ! void enable_command(adobe::name_t name, bool enabled); ! void do_command(adobe::name_t name); ! connection_t monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback); private: ! command_map_t command_map_m; }; --- 22,63 ---- struct command_system_t::implementation_t { ! struct command_entry_t ! { ! typedef boost::signal<void (bool)> enable_callback_list_t; ! command_entry_t() : ! enabled_m(false) ! { } ! command_entry_t(const command_entry_t& rhs) : ! enabled_m(rhs.enabled_m) ! { } ! command_entry_t& operator = (const command_entry_t& rhs) ! { ! enabled_m = rhs.enabled_m; ! return *this; ! } ! command_proc_t proc_m; ! bool enabled_m; ! enable_callback_list_t enabled_callback_m; ! }; ! typedef std::map<adobe::name_t, command_entry_t> command_map_t; ! void insert_command(adobe::name_t name, const command_proc_t& proc); ! void remove_command(adobe::name_t name); ! void enable_command(adobe::name_t name, bool enabled); ! void do_command(adobe::name_t name); ! connection_t monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback); private: ! command_map_t command_map_m; }; *************** *** 65,88 **** command_system_t::command_system_t() : ! object_m(new implementation_t()) ! { } command_system_t::~command_system_t() ! { delete object_m; } void command_system_t::insert_command(adobe::name_t name, const command_proc_t& proc) ! { object_m->insert_command(name, proc); } void command_system_t::remove_command(adobe::name_t name) ! { object_m->remove_command(name); } void command_system_t::enable_command(adobe::name_t name, bool enabled) ! { object_m->enable_command(name, enabled); } void command_system_t::do_command(adobe::name_t name) ! { object_m->do_command(name); } command_system_t::connection_t command_system_t::monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback) ! { return object_m->monitor_enabled(name, callback); } /****************************************************************************************************/ --- 65,88 ---- command_system_t::command_system_t() : ! object_m(new implementation_t()) ! { } command_system_t::~command_system_t() ! { delete object_m; } void command_system_t::insert_command(adobe::name_t name, const command_proc_t& proc) ! { object_m->insert_command(name, proc); } void command_system_t::remove_command(adobe::name_t name) ! { object_m->remove_command(name); } void command_system_t::enable_command(adobe::name_t name, bool enabled) ! { object_m->enable_command(name, enabled); } void command_system_t::do_command(adobe::name_t name) ! { object_m->do_command(name); } command_system_t::connection_t command_system_t::monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback) ! { return object_m->monitor_enabled(name, callback); } /****************************************************************************************************/ *************** *** 90,99 **** void command_system_t::implementation_t::insert_command(adobe::name_t name, const command_proc_t& proc) { ! if (command_map_m.find(name) != command_map_m.end()) ! throw std::runtime_error("A command by this name already exists"); ! command_entry_t& cmd(command_map_m[name]); ! cmd.proc_m = proc; } --- 90,99 ---- void command_system_t::implementation_t::insert_command(adobe::name_t name, const command_proc_t& proc) { ! if (command_map_m.find(name) != command_map_m.end()) ! throw std::runtime_error("A command by this name already exists"); ! command_entry_t& cmd(command_map_m[name]); ! cmd.proc_m = proc; } *************** *** 102,111 **** void command_system_t::implementation_t::remove_command(adobe::name_t name) { ! command_map_t::iterator item(command_map_m.find(name)); ! if (item == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_map_m.erase(item); } --- 102,111 ---- void command_system_t::implementation_t::remove_command(adobe::name_t name) { ! command_map_t::iterator item(command_map_m.find(name)); ! if (item == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_map_m.erase(item); } *************** *** 114,127 **** void command_system_t::implementation_t::enable_command(adobe::name_t name, bool enabled) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! if (cmd.enabled_m == enabled) return; ! cmd.enabled_m = enabled; ! cmd.enabled_callback_m(cmd.enabled_m); } --- 114,127 ---- void command_system_t::implementation_t::enable_command(adobe::name_t name, bool enabled) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! if (cmd.enabled_m == enabled) return; ! cmd.enabled_m = enabled; ! cmd.enabled_callback_m(cmd.enabled_m); } *************** *** 130,141 **** void command_system_t::implementation_t::do_command(adobe::name_t name) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! if (!cmd.enabled_m) return; ! cmd.proc_m(); } --- 130,141 ---- void command_system_t::implementation_t::do_command(adobe::name_t name) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! if (!cmd.enabled_m) return; ! cmd.proc_m(); } *************** *** 144,153 **** command_system_t::connection_t command_system_t::implementation_t::monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! return cmd.enabled_callback_m.connect(callback); } --- 144,153 ---- command_system_t::connection_t command_system_t::implementation_t::monitor_enabled(adobe::name_t name, const command_enabled_callback_t& callback) { ! if (command_map_m.find(name) == command_map_m.end()) ! throw std::runtime_error("A command by this name could not be found"); ! command_entry_t& cmd(command_map_m[name]); ! return cmd.enabled_callback_m.connect(callback); } Index: menu_system.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source/menu_system.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** menu_system.cpp 6 Jan 2006 18:02:57 -0000 1.2 --- menu_system.cpp 3 Feb 2006 18:33:36 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 24,45 **** /****************************************************************************************************/ ! const OSType app_creator_k ('adbe'); ! const OSType menu_system_tag_k ('mnsy'); /****************************************************************************************************/ ! #define ADOBE_DELETE_PTR_SPECIALIZATION(type, func) \ ! template<> \ ! struct delete_ptr<type> \ ! { \ ! void operator()(type x) const \ ! { if (x) func(x); } \ } /****************************************************************************************************/ ! ADOBE_DELETE_PTR_SPECIALIZATION(MenuRef, ::ReleaseMenu); ! ADOBE_DELETE_PTR_SPECIALIZATION(CFStringRef, ::CFRelease); ! ADOBE_DELETE_PTR_SPECIALIZATION(EventHandlerUPP, ::DisposeEventHandlerUPP); /****************************************************************************************************/ --- 24,45 ---- /****************************************************************************************************/ ! const OSType app_creator_k ('adbe'); ! const OSType menu_system_tag_k ('mnsy'); /****************************************************************************************************/ ! #define ADOBE_DELETE_PTR_SPECIALIZATION(type, func) \ ! template<> \ ! struct delete_ptr<type> \ ! { \ ! void operator()(type x) const \ ! { if (x) func(x); } \ } /****************************************************************************************************/ ! ADOBE_DELETE_PTR_SPECIALIZATION(MenuRef, ::ReleaseMenu); ! ADOBE_DELETE_PTR_SPECIALIZATION(CFStringRef, ::CFRelease); ! ADOBE_DELETE_PTR_SPECIALIZATION(EventHandlerUPP, ::DisposeEventHandlerUPP); /****************************************************************************************************/ *************** *** 48,122 **** { public: ! implementation_t(); ! ~implementation_t(); ! void insert_menu(adobe::name_t name); ! void insert_item(adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set); ! void insert_separator(adobe::name_t parent_name); ! void remove(adobe::name_t name); ! void enable_menu_item(adobe::name_t name, bool enabled, bool force = false); ! void mark_menu_item(adobe::name_t name, bool marked); ! connection_t monitor_menu_item(adobe::name_t name, const item_callback_t& callback); ! static void platform_initialization(); ! struct component_t ! { ! public: ! component_t() : ! enabled_m(false), ! command_id_m(next_menu_command()) ! { } ! component_t(const component_t& rhs) : ! name_m(rhs.name_m), ! ref_m(rhs.ref_m), ! enabled_m(rhs.enabled_m), ! //callback_set_m(rhs.callback_set_m), ! command_id_m(rhs.command_id_m) ! { } ! component_t& operator = (const component_t& rhs) ! { ! name_m = rhs.name_m; ! ref_m = rhs.ref_m; ! enabled_m = rhs.enabled_m; ! //callback_set_m = rhs.callback_set_m; ! const_cast<MenuCommand&>(command_id_m) = rhs.command_id_m; ! return *this; ! } ! adobe::name_t name_m; ! adobe::value_t ref_m; ! bool enabled_m; ! boost::signal<void ()> callback_signal_m; ! const MenuCommand command_id_m; ! private: ! ::MenuCommand next_menu_command() ! { ! static ::MenuCommand cur_cmd_m(1000000); ! return ++cur_cmd_m; ! } ! }; ! typedef std::list<component_t> component_set_t; ! typedef component_set_t::iterator component_iterator; ! adobe::auto_resource<MenuRef> old_root_m; ! adobe::auto_resource<MenuRef> root_m; ! component_set_t component_set_m; private: ! inline component_iterator find_iter(adobe::name_t name); ! component_t& find(adobe::name_t name); }; --- 48,122 ---- { public: ! implementation_t(); ! ~implementation_t(); ! void insert_menu(adobe::name_t name); ! void insert_item(adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set); ! void insert_separator(adobe::name_t parent_name); ! void remove(adobe::name_t name); ! void enable_menu_item(adobe::name_t name, bool enabled, bool force = false); ! void mark_menu_item(adobe::name_t name, bool marked); ! connection_t monitor_menu_item(adobe::name_t name, const item_callback_t& callback); ! static void platform_initialization(); ! struct component_t ! { ! public: ! component_t() : ! enabled_m(false), ! command_id_m(next_menu_command()) ! { } ! component_t(const component_t& rhs) : ! name_m(rhs.name_m), ! ref_m(rhs.ref_m), ! enabled_m(rhs.enabled_m), ! //callback_set_m(rhs.callback_set_m), ! command_id_m(rhs.command_id_m) ! { } ! component_t& operator = (const component_t& rhs) ! { ! name_m = rhs.name_m; ! ref_m = rhs.ref_m; ! enabled_m = rhs.enabled_m; ! //callback_set_m = rhs.callback_set_m; ! const_cast<MenuCommand&>(command_id_m) = rhs.command_id_m; ! return *this; ! } ! adobe::name_t name_m; ! adobe::value_t ref_m; ! bool enabled_m; ! boost::signal<void ()> callback_signal_m; ! const MenuCommand command_id_m; ! private: ! ::MenuCommand next_menu_command() ! { ! static ::MenuCommand cur_cmd_m(1000000); ! return ++cur_cmd_m; ! } ! }; ! typedef std::list<component_t> component_set_t; ! typedef component_set_t::iterator component_iterator; ! adobe::auto_resource<MenuRef> old_root_m; ! adobe::auto_resource<MenuRef> root_m; ! component_set_t component_set_m; private: ! inline component_iterator find_iter(adobe::name_t name); ! component_t& find(adobe::name_t name); }; *************** *** 133,154 **** std::string cfstring_to_string(CFStringRef x) { ! if (x == 0) return std::string(); ! const int pad(16); // must be at least one - seems like a good conservative size ! CFIndex max_size(::CFStringGetMaximumSizeForEncoding(::CFStringGetLength(x), ! kCFStringEncodingUTF8) + pad); ! std::vector<char> buffer(static_cast<std::size_t>(max_size)); #ifndef NDEBUG ! Boolean result = #endif ! ::CFStringGetCString(x, &buffer[0], max_size, kCFStringEncodingUTF8); #ifndef NDEBUG ! assert(result); #endif ! return std::string(&buffer[0]); } --- 133,154 ---- std::string cfstring_to_string(CFStringRef x) { ! if (x == 0) return std::string(); ! const int pad(16); // must be at least one - seems like a good conservative size ! CFIndex max_size(::CFStringGetMaximumSizeForEncoding(::CFStringGetLength(x), ! kCFStringEncodingUTF8) + pad); ! std::vector<char> buffer(static_cast<std::size_t>(max_size)); #ifndef NDEBUG ! Boolean result = #endif ! ::CFStringGetCString(x, &buffer[0], max_size, kCFStringEncodingUTF8); #ifndef NDEBUG ! assert(result); #endif ! return std::string(&buffer[0]); } *************** *** 157,166 **** adobe::auto_resource<CFStringRef> string_to_cfstring(const std::string& x) { ! adobe::auto_resource<CFStringRef> ! convertedString(::CFStringCreateWithCString( NULL, ! x.c_str(), ! kCFStringEncodingUTF8)); ! return convertedString; } --- 157,166 ---- adobe::auto_resource<CFStringRef> string_to_cfstring(const std::string& x) { ! adobe::auto_resource<CFStringRef> ! convertedString(::CFStringCreateWithCString( NULL, ! x.c_str(), ! kCFStringEncodingUTF8)); ! return convertedString; } *************** *** 170,209 **** try { ! HICommand command; ! adobe::auto_resource<MenuRef> root(::AcquireRootMenu()); ! adobe::menu_system_t::implementation_t* impl(0); ! UInt32 actual_size(0); ! ADOBE_REQUIRE_STATUS(::GetMenuItemProperty( root.get(), 0, ! adobe::app_creator_k, ! adobe::menu_system_tag_k, ! sizeof(impl), ! &actual_size, &impl)); ! assert(actual_size == sizeof(impl)); ! assert(impl); ! if( ::GetEventParameter( event, kEventParamDirectObject, ! typeHICommand, 0, sizeof( command ), 0, &command ) ) ! return eventNotHandledErr; ! adobe::menu_system_t::implementation_t::component_iterator item = ! adobe::find_if( impl->component_set_m, ! boost::bind(adobe::compare_members( ! &adobe::menu_system_t::implementation_t::component_t::command_id_m, ! std::equal_to< ::MenuCommand>()), ! command.commandID, ! _1)); ! if (item == impl->component_set_m.end()) ! return eventNotHandledErr; ! item->callback_signal_m(); ! return noErr; } catch( ... ) { ! return eventNotHandledErr; } --- 170,209 ---- try { ! HICommand command; ! adobe::auto_resource<MenuRef> root(::AcquireRootMenu()); ! adobe::menu_system_t::implementation_t* impl(0); ! UInt32 actual_size(0); ! ADOBE_REQUIRE_STATUS(::GetMenuItemProperty( root.get(), 0, ! adobe::app_creator_k, ! adobe::menu_system_tag_k, ! sizeof(impl), ! &actual_size, &impl)); ! assert(actual_size == sizeof(impl)); ! assert(impl); ! if( ::GetEventParameter( event, kEventParamDirectObject, ! typeHICommand, 0, sizeof( command ), 0, &command ) ) ! return eventNotHandledErr; ! adobe::menu_system_t::implementation_t::component_iterator item = ! adobe::find_if( impl->component_set_m, ! boost::bind(adobe::compare_members( ! &adobe::menu_system_t::implementation_t::component_t::command_id_m, ! std::equal_to< ::MenuCommand>()), ! command.commandID, ! _1)); ! if (item == impl->component_set_m.end()) ! return eventNotHandledErr; ! item->callback_signal_m(); ! return noErr; } catch( ... ) { ! return eventNotHandledErr; } *************** *** 212,218 **** ::MenuID next_menu_id() { ! static ::MenuID id(12345); ! return ++id; } --- 212,218 ---- ::MenuID next_menu_id() { ! static ::MenuID id(12345); ! return ++id; } *************** *** 228,261 **** menu_system_t::menu_system_t() : ! object_m(new implementation_t()) ! { implementation_t::platform_initialization(); } menu_system_t::~menu_system_t() ! { delete object_m; } void menu_system_t::insert_menu(adobe::name_t name) ! { object_m->insert_menu(name); } ! void menu_system_t::insert_item(adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set) ! { object_m->insert_item(parent_name, name, cmd_key, modifier_set); } void menu_system_t::insert_separator(adobe::name_t parent_name) ! { object_m->insert_separator(parent_name); } void menu_system_t::remove(adobe::name_t name) ! { object_m->remove(name); } void menu_system_t::enable_menu_item(adobe::name_t name, bool enabled) ! { object_m->enable_menu_item(name, enabled); } void menu_system_t::mark_menu_item(adobe::name_t name, bool marked) ! { object_m->mark_menu_item(name, marked); } ! menu_system_t::connection_t menu_system_t::monitor_menu_item( adobe::name_t name, ! const item_callback_t& callback) ! { return object_m->monitor_menu_item(name, callback); } /****************************************************************************************************/ --- 228,261 ---- menu_system_t::menu_system_t() : ! object_m(new implementation_t()) ! { implementation_t::platform_initialization(); } menu_system_t::~menu_system_t() ! { delete object_m; } void menu_system_t::insert_menu(adobe::name_t name) ! { object_m->insert_menu(name); } ! void menu_system_t::insert_item(adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set) ! { object_m->insert_item(parent_name, name, cmd_key, modifier_set); } void menu_system_t::insert_separator(adobe::name_t parent_name) ! { object_m->insert_separator(parent_name); } void menu_system_t::remove(adobe::name_t name) ! { object_m->remove(name); } void menu_system_t::enable_menu_item(adobe::name_t name, bool enabled) ! { object_m->enable_menu_item(name, enabled); } void menu_system_t::mark_menu_item(adobe::name_t name, bool marked) ! { object_m->mark_menu_item(name, marked); } ! menu_system_t::connection_t menu_system_t::monitor_menu_item( adobe::name_t name, ! const item_callback_t& callback) ! { return object_m->monitor_menu_item(name, callback); } /****************************************************************************************************/ *************** *** 268,290 **** menu_system_t::implementation_t::implementation_t() : ! old_root_m(::AcquireRootMenu()) { ! MenuRef new_root; ! menu_system_t::implementation_t* ptr(this); ! ADOBE_REQUIRE_STATUS(::CreateNewMenu(next_menu_id(), 0, &new_root)); ! ADOBE_REQUIRE_STATUS(::SetMenuItemProperty( new_root, 0, ! adobe::app_creator_k, ! adobe::menu_system_tag_k, ! sizeof(ptr), ! &ptr)); ! root_m.reset(new_root); ! ::SetRootMenu(new_root); ! ::InvalMenuBar(); ! ::DrawMenuBar(); } --- 268,290 ---- menu_system_t::implementation_t::implementation_t() : ! old_root_m(::AcquireRootMenu()) { ! MenuRef new_root; ! menu_system_t::implementation_t* ptr(this); ! ADOBE_REQUIRE_STATUS(::CreateNewMenu(next_menu_id(), 0, &new_root)); ! ADOBE_REQUIRE_STATUS(::SetMenuItemProperty( new_root, 0, ! adobe::app_creator_k, ! adobe::menu_system_tag_k, ! sizeof(ptr), ! &ptr)); ! root_m.reset(new_root); ! ::SetRootMenu(new_root); ! ::InvalMenuBar(); ! ::DrawMenuBar(); } *************** *** 293,300 **** menu_system_t::implementation_t::~implementation_t() { ! ::SetRootMenu(old_root_m.get()); ! ::InvalMenuBar(); ! ::DrawMenuBar(); } --- 293,300 ---- menu_system_t::implementation_t::~implementation_t() { ! ::SetRootMenu(old_root_m.get()); ! ::InvalMenuBar(); ! ::DrawMenuBar(); } *************** *** 303,316 **** void menu_system_t::implementation_t::platform_initialization() { ! static EventTypeSpec hi_event = { kEventClassCommand, kHICommandFromMenu }; ! static adobe::auto_resource<EventHandlerUPP> hi_handler( ::NewEventHandlerUPP( &::menu_command ) ); ! static bool init(false); ! if (!init) ! { ! ::InstallApplicationEventHandler( hi_handler.get(), 1, &hi_event, 0, 0 ); ! init = true; ! } } --- 303,316 ---- void menu_system_t::implementation_t::platform_initialization() { ! static EventTypeSpec hi_event = { kEventClassCommand, kHICommandFromMenu }; ! static adobe::auto_resource<EventHandlerUPP> hi_handler( ::NewEventHandlerUPP( &::menu_command ) ); ! static bool init(false); ! if (!init) ! { ! ::InstallApplicationEventHandler( hi_handler.get(), 1, &hi_event, 0, 0 ); ! init = true; ! } } *************** *** 319,325 **** inline menu_system_t::implementation_t::component_iterator menu_system_t::implementation_t::find_iter(adobe::name_t name) { ! return adobe::find_if(component_set_m, ! boost::bind(adobe::compare_members(&component_t::name_m, ! std::equal_to<adobe::name_t>()), name, _1)); } --- 319,325 ---- inline menu_system_t::implementation_t::component_iterator menu_system_t::implementation_t::find_iter(adobe::name_t name) { ! return adobe::find_if(component_set_m, ! boost::bind(adobe::compare_members(&component_t::name_m, ! std::equal_to<adobe::name_t>()), name, _1)); } *************** *** 328,336 **** menu_system_t::implementation_t::component_t& menu_system_t::implementation_t::find(adobe::name_t name) { ! component_iterator item(find_iter(name)); ! if (item == component_set_m.end()) throw std::runtime_error("Item not found."); ! return *item; } --- 328,336 ---- menu_system_t::implementation_t::component_t& menu_system_t::implementation_t::find(adobe::name_t name) { ! component_iterator item(find_iter(name)); ! if (item == component_set_m.end()) throw std::runtime_error("Item not found."); ! return *item; } *************** *** 339,396 **** void menu_system_t::implementation_t::insert_menu(adobe::name_t name) { ! MenuRef new_menu(0); ! ADOBE_REQUIRE_STATUS(::CreateNewMenu(next_menu_id(), 0, &new_menu)); ! ADOBE_REQUIRE_STATUS(::SetMenuTitleWithCFString(new_menu, string_to_cfstring(name.get()).get())); ! ::InsertMenu(new_menu, 0); ! component_set_m.push_back(component_t()); ! component_set_m.back().name_m = name; ! component_set_m.back().ref_m = adobe::value_t(new_menu); } /****************************************************************************************************/ ! void menu_system_t::implementation_t::insert_item( adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set) { ! component_t& parent(find(parent_name)); ! assert (parent.ref_m.type() == typeid(::MenuRef)); ! ::MenuRef parent_menu_ref(parent.ref_m.get< ::MenuRef>()); ! component_set_m.push_back(component_t()); ! component_set_m.back().name_m = name; ! UInt16 count(::CountMenuItems(parent_menu_ref) + 1); ! ADOBE_REQUIRE_STATUS(::InsertMenuItemTextWithCFString( ! parent_menu_ref, ! string_to_cfstring(name.get()).get(), ! count, ! kMenuItemAttrDisabled, ! component_set_m.back().command_id_m)); ! if (cmd_key != boost::uint16_t(0)) ! { ! ADOBE_REQUIRE_STATUS(::SetMenuItemCommandKey(parent_menu_ref, count, false, cmd_key)); ! if (modifier_set != modifier_none_k) ! { ! UInt8 os_modifier_set(kMenuNoModifiers); ! if (modifier_set & modifier_option_k) os_modifier_set |= kMenuOptionModifier; ! if (modifier_set & modifier_control_k) os_modifier_set |= kMenuControlModifier; ! if (modifier_set & modifier_shift_k) os_modifier_set |= kMenuShiftModifier; ! ADOBE_REQUIRE_STATUS(::SetMenuItemModifiers(parent_menu_ref, count, os_modifier_set)); ! } ! } } --- 339,396 ---- void menu_system_t::implementation_t::insert_menu(adobe::name_t name) { ! MenuRef new_menu(0); ! ADOBE_REQUIRE_STATUS(::CreateNewMenu(next_menu_id(), 0, &new_menu)); ! ADOBE_REQUIRE_STATUS(::SetMenuTitleWithCFString(new_menu, string_to_cfstring(name.get()).get())); ! ::InsertMenu(new_menu, 0); ! component_set_m.push_back(component_t()); ! component_set_m.back().name_m = name; ! component_set_m.back().ref_m = adobe::value_t(new_menu); } /****************************************************************************************************/ ! void menu_system_t::implementation_t::insert_item( adobe::name_t parent_name, ! adobe::name_t name, ! boost::uint16_t cmd_key, ! modifier_set_t modifier_set) { ! component_t& parent(find(parent_name)); ! assert (parent.ref_m.type() == typeid(::MenuRef)); ! ::MenuRef parent_menu_ref(parent.ref_m.get< ::MenuRef>()); ! component_set_m.push_back(component_t()); ! component_set_m.back().name_m = name; ! UInt16 count(::CountMenuItems(parent_menu_ref) + 1); ! ADOBE_REQUIRE_STATUS(::InsertMenuItemTextWithCFString( ! parent_menu_ref, ! string_to_cfstring(name.get()).get(), ! count, ! kMenuItemAttrDisabled, ! component_set_m.back().command_id_m)); ! if (cmd_key != boost::uint16_t(0)) ! { ! ADOBE_REQUIRE_STATUS(::SetMenuItemCommandKey(parent_menu_ref, count, false, cmd_key)); ! if (modifier_set != modifier_none_k) ! { ! UInt8 os_modifier_set(kMenuNoModifiers); ! if (modifier_set & modifier_option_k) os_modifier_set |= kMenuOptionModifier; ! if (modifier_set & modifier_control_k) os_modifier_set |= kMenuControlModifier; ! if (modifier_set & modifier_shift_k) os_modifier_set |= kMenuShiftModifier; ! ADOBE_REQUIRE_STATUS(::SetMenuItemModifiers(parent_menu_ref, count, os_modifier_set)); ! } ! } } *************** *** 399,414 **** void menu_system_t::implementation_t::insert_separator(adobe::name_t parent_name) { ! component_t& parent(find(parent_name)); ! assert (parent.ref_m.type() == typeid(::MenuRef)); ! ::MenuRef parent_menu_ref(parent.ref_m.get< ::MenuRef>()); ! ADOBE_REQUIRE_STATUS(::InsertMenuItemTextWithCFString( ! parent_menu_ref, ! CFSTR(""), ! 999999, ! kMenuItemAttrSeparator, ! 0)); } --- 399,414 ---- void menu_system_t::implementation_t::insert_separator(adobe::name_t parent_name) { ! component_t& parent(find(parent_name)); ! assert (parent.ref_m.type() == typeid(::MenuRef)); ! ::MenuRef parent_menu_ref(parent.ref_m.get< ::MenuRef>()); ! ADOBE_REQUIRE_STATUS(::InsertMenuItemTextWithCFString( ! parent_menu_ref, ! CFSTR(""), ! 999999, ! kMenuItemAttrSeparator, ! 0)); } *************** *** 417,434 **** void menu_system_t::implementation_t::remove(adobe::name_t name) { ! component_iterator item(find_iter(name)); ! if (item == component_set_m.end()) return; ! assert (::CountMenuItemsWithCommandID(0, item->command_id_m) > 0); ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item->command_id_m, 1, &found_menu_ref, &found_index)); ! ::DeleteMenuItem(found_menu_ref, found_index); ! component_set_m.erase(item); } --- 417,434 ---- void menu_system_t::implementation_t::remove(adobe::name_t name) { ! component_iterator item(find_iter(name)); ! if (item == component_set_m.end()) return; ! assert (::CountMenuItemsWithCommandID(0, item->command_id_m) > 0); ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item->command_id_m, 1, &found_menu_ref, &found_index)); ! ::DeleteMenuItem(found_menu_ref, found_index); ! component_set_m.erase(item); } *************** *** 437,458 **** void menu_system_t::implementation_t::enable_menu_item(adobe::name_t name, bool enabled, bool force) { ! component_t& item(find(name)); ! if (item.enabled_m == enabled && !force) return; ! item.enabled_m = enabled; ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! assert (::CountMenuItemsWithCommandID(0, item.command_id_m) > 0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item.command_id_m, 1, &found_menu_ref, &found_index)); ! item.enabled_m ? ! ::EnableMenuItem(found_menu_ref, found_index) : ! ::DisableMenuItem(found_menu_ref, found_index); ! assert (IsMenuCommandEnabled(0, item.command_id_m) == item.enabled_m); } --- 437,458 ---- void menu_system_t::implementation_t::enable_menu_item(adobe::name_t name, bool enabled, bool force) { ! component_t& item(find(name)); ! if (item.enabled_m == enabled && !force) return; ! item.enabled_m = enabled; ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! assert (::CountMenuItemsWithCommandID(0, item.command_id_m) > 0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item.command_id_m, 1, &found_menu_ref, &found_index)); ! item.enabled_m ? ! ::EnableMenuItem(found_menu_ref, found_index) : ! ::DisableMenuItem(found_menu_ref, found_index); ! assert (IsMenuCommandEnabled(0, item.command_id_m) == item.enabled_m); } *************** *** 461,474 **** void menu_system_t::implementation_t::mark_menu_item(adobe::name_t name, bool marked) { ! component_t& item(find(name)); ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! assert (::CountMenuItemsWithCommandID(0, item.command_id_m) > 0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item.command_id_m, 1, &found_menu_ref, &found_index)); ! ::CheckMenuItem(found_menu_ref, found_index, marked); } --- 461,474 ---- void menu_system_t::implementation_t::mark_menu_item(adobe::name_t name, bool marked) { ! component_t& item(find(name)); ! MenuRef found_menu_ref(0); ! MenuItemIndex found_index(0); ! assert (::CountMenuItemsWithCommandID(0, item.command_id_m) > 0); ! ADOBE_REQUIRE_STATUS(::GetIndMenuItemWithCommandID(0, item.command_id_m, 1, &found_menu_ref, &found_index)); ! ::CheckMenuItem(found_menu_ref, found_index, marked); } *************** *** 477,483 **** menu_system_t::connection_t menu_system_t::implementation_t::monitor_menu_item(adobe::name_t name, const item_callback_t& callback) { ! component_t& item(find(name)); ! return item.callback_signal_m.connect(callback); } --- 477,483 ---- menu_system_t::connection_t menu_system_t::implementation_t::monitor_menu_item(adobe::name_t name, const item_callback_t& callback) { ! component_t& item(find(name)); ! return item.callback_signal_m.connect(callback); } Index: iomanip_asl_cel.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source/iomanip_asl_cel.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** iomanip_asl_cel.cpp 6 Jan 2006 18:02:57 -0000 1.4 --- iomanip_asl_cel.cpp 3 Feb 2006 18:33:36 -0000 1.5 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 20,210 **** void asl_cel_format::begin_format(stream_type& os) ! { ! push_stack(os, new asl_cel_format_element(name_t("asl_cel"))); ! } /*************************************************************************************************/ void asl_cel_format::begin_bag(stream_type& os, const std::string& ident) ! { ! push_stack(os, new asl_cel_format_element(bag_name_g, ident)); ! } /*************************************************************************************************/ void asl_cel_format::begin_sequence(stream_type& os) ! { ! push_stack(os, new asl_cel_format_element(seq_name_g)); ! } /*************************************************************************************************/ void asl_cel_format::begin_atom(stream_type& os, const std::type_info& typeinfo) ! { ! push_stack(os, new asl_cel_format_element(atom_name_g, typeinfo)); ! } /*************************************************************************************************/ void asl_cel_format::stack_event(stream_type& os, bool is_push) ! { ! asl_cel_format_element* top(my_stack_top()); ! name_t self(top ? top->tag() : "ERROR"); ! name_t parent(stack_depth() >= 2 ? stack_n(1)->tag() : ""); ! name_t grandparent(stack_depth() >= 3 ? stack_n(2)->tag() : ""); ! if (is_push) ! { ! if (self == static_name_t("asl_cel")) ! { ! //os << "\n"; ! } ! else if (self == bag_name_g) ! { ! if (parent != atom_name_g) ! os << indents(depth()); ! os << "{\n"; ! up(); ! } ! else if (self == seq_name_g) ! { ! if (parent != bag_name_g) ! { ! if (parent != atom_name_g) ! os << indents(depth()); ! os << "[ "; ! } ! } ! else if (self == atom_name_g) ! { ! handle_atom(os, is_push); ! } ! } ! else ! { ! if (self == static_name_t("asl_cel")) ! { ! //os << "\n"; ! } ! else if (self == bag_name_g) ! { ! down(); ! os << indents(depth()) << "}"; ! if (parent != atom_name_g) ! { ! os << "\n"; ! } ! } ! else if (self == seq_name_g) ! { ! if (parent == bag_name_g) ! { ! os << "\n"; ! } ! else ! { ! os << "]"; ! if (parent != atom_name_g) ! { ! os << "\n"; ! } ! } ! } ! else if (self == atom_name_g) ! { ! handle_atom(os, is_push); ! } ! } ! } /*************************************************************************************************/ void asl_cel_format::handle_atom(stream_type& os, bool is_push) ! { ! asl_cel_format_element* top(my_stack_top()); ! name_t self(top ? top->tag() : "ERROR"); ! name_t parent(stack_depth() >= 2 ? stack_n(1)->tag() : ""); ! name_t grandparent(stack_depth() >= 3 ? stack_n(2)->tag() : ""); ! if (!top) ! return; ! const std::type_info& top_type(top->type()); ! if (is_push) ! { ! if (implementation::type_string(top_type)) ! { ! if (parent != seq_name_g) ! os << indents(depth()); ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! os << indents(depth()) << "@"; ! else ! os << "'"; ! } ! else if (implementation::type_name(top_type)) ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! os << indents(depth()); ! else ! os << "@"; ! } ! else if (implementation::type_float(top_type)) ! { ! // For asl_cel, we want to output floating-point values in decimal-based ! // fixed-point notation (asl_cel doesn't support any other format) with ! // a very high precision for accceptable roundtrip values. ! os.setf(std::ios_base::dec, std::ios_base::basefield); ! os.setf(std::ios_base::fixed, std::ios_base::floatfield); ! os.precision(16); ! } ! // other data type format stuff goes here ! } ! else ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! { } ! else ! { ! if (implementation::type_string(top_type)) ! { ! os << "'"; ! } ! else if (implementation::type_float(top_type)) ! { ! // For asl_cel, we want to output floating-point values in decimal-based ! // fixed-point notation (asl_cel doesn't support any other format) with ! // a very high precision for accceptable roundtrip values. ! os.setf(std::ios_base::dec, std::ios_base::basefield); ! os.setf(std::ios_base::fixed, std::ios_base::floatfield); ! os.precision(16); ! } ! // other data type format stuff goes here ! } ! if (parent == seq_name_g) ! { ! my_stack_n(1)->num_out_m++; ! os << " "; ! } ! else if (implementation::type_name(top_type)) ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! { os << ": "; } ! else ! { /*os << " ";*/ } ! } ! else if (implementation::type_integer(top_type)) ! { /* do nothing */ } ! else ! os << "\n"; ! } } --- 20,210 ---- void asl_cel_format::begin_format(stream_type& os) ! { ! push_stack(os, new asl_cel_format_element(name_t("asl_cel"))); ! } /*************************************************************************************************/ void asl_cel_format::begin_bag(stream_type& os, const std::string& ident) ! { ! push_stack(os, new asl_cel_format_element(bag_name_g, ident)); ! } /*************************************************************************************************/ void asl_cel_format::begin_sequence(stream_type& os) ! { ! push_stack(os, new asl_cel_format_element(seq_name_g)); ! } /*************************************************************************************************/ void asl_cel_format::begin_atom(stream_type& os, const std::type_info& typeinfo) ! { ! push_stack(os, new asl_cel_format_element(atom_name_g, typeinfo)); ! } /*************************************************************************************************/ void asl_cel_format::stack_event(stream_type& os, bool is_push) ! { ! asl_cel_format_element* top(my_stack_top()); ! name_t self(top ? top->tag() : "ERROR"); ! name_t parent(stack_depth() >= 2 ? stack_n(1)->tag() : ""); ! name_t grandparent(stack_depth() >= 3 ? stack_n(2)->tag() : ""); ! if (is_push) ! { ! if (self == static_name_t("asl_cel")) ! { ! //os << "\n"; ! } ! else if (self == bag_name_g) ! { ! if (parent != atom_name_g) ! os << indents(depth()); ! os << "{\n"; ! up(); ! } ! else if (self == seq_name_g) ! { ! if (parent != bag_name_g) ! { ! if (parent != atom_name_g) ! os << indents(depth()); ! os << "[ "; ! } ! } ! else if (self == atom_name_g) ! { ! handle_atom(os, is_push); ! } ! } ! else ! { ! if (self == static_name_t("asl_cel")) ! { ! //os << "\n"; ! } ! else if (self == bag_name_g) ! { ! down(); ! os << indents(depth()) << "}"; ! if (parent != atom_name_g) ! { ! os << "\n"; ! } ! } ! else if (self == seq_name_g) ! { ! if (parent == bag_name_g) ! { ! os << "\n"; ! } ! else ! { ! os << "]"; ! if (parent != atom_name_g) ! { ! os << "\n"; ! } ! } ! } ! else if (self == atom_name_g) ! { ! handle_atom(os, is_push); ! } ! } ! } /*************************************************************************************************/ void asl_cel_format::handle_atom(stream_type& os, bool is_push) ! { ! asl_cel_format_element* top(my_stack_top()); ! name_t self(top ? top->tag() : "ERROR"); ! name_t parent(stack_depth() >= 2 ? stack_n(1)->tag() : ""); ! name_t grandparent(stack_depth() >= 3 ? stack_n(2)->tag() : ""); ! if (!top) ! return; ! const std::type_info& top_type(top->type()); ! if (is_push) ! { ! if (implementation::type_string(top_type)) ! { ! if (parent != seq_name_g) ! os << indents(depth()); ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! os << indents(depth()) << "@"; ! else ! os << "'"; ! } ! else if (implementation::type_name(top_type)) ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! os << indents(depth()); ! else ! os << "@"; ! } ! else if (implementation::type_float(top_type)) ! { ! // For asl_cel, we want to output floating-point values in decimal-based ! // fixed-point notation (asl_cel doesn't support any other format) with ! // a very high precision for accceptable roundtrip values. ! os.setf(std::ios_base::dec, std::ios_base::basefield); ! os.setf(std::ios_base::fixed, std::ios_base::floatfield); ! os.precision(16); ! } ! // other data type format stuff goes here ! } ! else ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! { } ! else ! { ! if (implementation::type_string(top_type)) ! { ! os << "'"; ! } ! else if (implementation::type_float(top_type)) ! { ! // For asl_cel, we want to output floating-point values in decimal-based ! // fixed-point notation (asl_cel doesn't support any other format) with ! // a very high precision for accceptable roundtrip values. ! os.setf(std::ios_base::dec, std::ios_base::basefield); ! os.setf(std::ios_base::fixed, std::ios_base::floatfield); ! os.precision(16); ! } ! // other data type format stuff goes here ! } ! if (parent == seq_name_g) ! { ! my_stack_n(1)->num_out_m++; ! os << " "; ! } ! else if (implementation::type_name(top_type)) ! { ! if (parent == seq_name_g && grandparent == bag_name_g && my_stack_n(1)->num_out_m == 0) ! { os << ": "; } ! else ! { /*os << " ";*/ } ! } ! else if (implementation::type_integer(top_type)) ! { /* do nothing */ } ! else ! os << "\n"; ! } } *************** *** 212,243 **** asl_cel_format_element* asl_cel_format::my_stack_top() ! { ! return my_stack_n(0); ! } /*************************************************************************************************/ asl_cel_format_element* asl_cel_format::my_stack_n(std::size_t n) ! { ! format_base::stack_element_type element(stack_n(n)); ! return dynamic_cast<asl_cel_format_element*>(element); ! } /*************************************************************************************************/ std::ostream& begin_asl_cel(std::ostream& os) ! { ! replace_pword<format_base, asl_cel_format>(os, format_base_idx()); ! os << begin_format; ! return os; ! } /*************************************************************************************************/ std::ostream& end_asl_cel(std::ostream& os) ! { ! os << end_format; ! return os; ! } /*************************************************************************************************/ --- 212,243 ---- asl_cel_format_element* asl_cel_format::my_stack_top() ! { ! return my_stack_n(0); ! } /*************************************************************************************************/ asl_cel_format_element* asl_cel_format::my_stack_n(std::size_t n) ! { ! format_base::stack_element_type element(stack_n(n)); ! return dynamic_cast<asl_cel_format_element*>(element); ! } /*************************************************************************************************/ std::ostream& begin_asl_cel(std::ostream& os) ! { ! replace_pword<format_base, asl_cel_format>(os, format_base_idx()); ! os << begin_format; ! return os; ! } /*************************************************************************************************/ std::ostream& end_asl_cel(std::ostream& os) ! { ! os << end_format; ! return os; ! } /*************************************************************************************************/ Index: assemblage.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source/assemblage.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** assemblage.cpp 6 Jan 2006 18:02:57 -0000 1.3 --- assemblage.cpp 3 Feb 2006 18:33:36 -0000 1.4 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 24,43 **** assemblage_t::~assemblage_t() { ! // disconnect all our connections ! adobe::for_each(connections_m, boost::bind(&connection_t::disconnect, _1)); /* ! REVISIT (sparent) : This should be ! ! adobe::for_each_reverse(destruct_signal_m, adobe::apply()); */ ! for (destruct_signal_t::iterator last(destruct_signal_m.end()), ! first(destruct_signal_m.begin()); first != last; ) ! { ! --last; ! (*last)(); ! } } --- 24,43 ---- assemblage_t::~assemblage_t() { ! // disconnect all our connections ! adobe::for_each(connections_m, boost::bind(&connection_t::disconnect, _1)); /* ! REVISIT (sparent) : This should be ! ! adobe::for_each_reverse(destruct_signal_m, adobe::apply()); */ ! for (destruct_signal_t::iterator last(destruct_signal_m.end()), ! first(destruct_signal_m.begin()); first != last; ) ! { ! --last; ! (*last)(); ! } } *************** *** 46,52 **** assemblage_t::connection_t& assemblage_t::hold_connection(const connection_t& connection) { ! connections_m.push_front(connection); ! return *connections_m.begin(); } --- 46,52 ---- assemblage_t::connection_t& assemblage_t::hold_connection(const connection_t& connection) { ! connections_m.push_front(connection); ! return *connections_m.begin(); } *************** *** 55,59 **** void assemblage_t::signal_destruction(const destruct_slot_t& slot) { ! destruct_signal_m.push_back(slot); } --- 55,59 ---- void assemblage_t::signal_destruction(const destruct_slot_t& slot) { ! destruct_signal_m.push_back(slot); } Index: modal_dialog_interface.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/source/modal_dialog_interface.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** modal_dialog_interface.cpp 24 Jan 2006 19:38:46 -0000 1.1 --- modal_dialog_interface.cpp 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 15,25 **** #if ADOBE_PLATFORM_MAC ! #include <adobe/future/widgets/headers/mac/carbon_safe.hpp> #elif ADOBE_PLATFORM_WIN ! #define WINDOWS_LEAN_AND_MEAN 1 ! #include <windows.h> ! #include <adobe/future/widgets/headers/win32/event_dispatcher.hpp> #endif --- 15,25 ---- #if ADOBE_PLATFORM_MAC ! #include <adobe/future/widgets/headers/mac/carbon_safe.hpp> #elif ADOBE_PLATFORM_WIN ! #define WINDOWS_LEAN_AND_MEAN 1 ! #include <windows.h> ! #include <adobe/future/widgets/headers/win32/event_dispatcher.hpp> #endif *************** *** 32,239 **** std::string getline(std::istream& stream) { ! std::string result; ! result.reserve(128); ! while (true) ! { ! int c(stream.get()); ! if (c == EOF || c == '\n' || c == '\r') ! break; ! result += static_cast<char>(c); ! } ! return result; } /****************************************************************************************************/ ! std::string mdi_getline(std::istream& layout_definition, adobe::name_t, std::streampos line_start_position) { ! std::streampos old_pos(layout_definition.tellg()); ! layout_definition.clear(); ! layout_definition.seekg(line_start_position); ! std::string result(getline(layout_definition)); ! layout_definition.seekg(old_pos); ! return result; } /****************************************************************************************************/ ! struct mdi_op_callback_t { ! typedef void result_type; ! mdi_op_callback_t() : ! view_m(0) ! { } ! void callback(adobe::name_t, const adobe::value_t&) ! try ! { ! assert(view_m); ! // system_beep(); // unknown request. ! #if ADOBE_PLATFORM_MAC ! HIViewRef cntl(adobe::unwrap_display_token<HIViewRef>(view_m->root_display_m)); ! WindowRef owner(::GetControlOwner(cntl)); ! ::QuitAppModalLoopForWindow(owner); ! #elif ADOBE_PLATFORM_WIN ! ::PostQuitMessage(0); ! #endif ! } ! catch(...) ! { ! std::cerr << "Exception caught in mdi_op_callback" << std::endl; ! } ! eve_client::eve_client_holder* view_m; ! }; ! /****************************************************************************************************/ ! void monitor_invariant(bool& need_ui, bool is_set) ! { ! need_ui = !is_set; ! } ! /****************************************************************************************************/ ! adobe::dialog_result_t handle_dialog( const adobe::dictionary_t& input, ! const adobe::record_info_t& record, ! const adobe::dictionary_t& display_state, ! adobe::display_options_t display_options, ! std::istream& layout_definition, ! std::istream& sheet_definition) ! { ! assert ( !layout_definition.fail() ); ! assert ( !sheet_definition.fail() ); ! adobe::dialog_result_t result; ! adobe::sheet_t sheet; ! adobe::auto_ptr<eve_client::eve_client_holder> view; ! mdi_op_callback_t view_callback; ! // ! // Parse the Adam stream ! // ! adobe::parse( sheet_definition, adobe::line_position_t( "Adam sheet definition" ), adobe::bind_to_sheet( sheet ) ); ! // ! // Set up the sheet with initial inputs, etc. ! // ! for (adobe::dictionary_t::const_iterator first(input.begin()), last(input.end()); first != last; ++first) ! sheet.set(first->first, first->second); ! for (adobe::dictionary_t::const_iterator first(record.first.begin()), last(record.first.end()); first != last; ++first) ! sheet.set(first->first, first->second); ! if (!record.second.empty()) ! { ! std::vector<adobe::name_t> touch_set; ! for (adobe::array_t::const_iterator first(record.second.begin()), last(record.second.end()); first != last; ++first) ! touch_set.push_back(first->get<adobe::name_t>()); ! const adobe::name_t* touch_first(&touch_set.front()); ! const adobe::name_t* touch_last(&touch_set.back()); ! sheet.touch(touch_first, ++touch_last); ! } ! bool need_ui(false); ! sheet.monitor_invariant_dependent(adobe::static_name_t("result"), boost::bind(&monitor_invariant, boost::ref(need_ui), _1)); ! sheet.update(); ! if (display_options == dialog_never_display_s && need_ui) ! throw std::runtime_error("handle_dialog: Invalid command parameters and UI not permitted."); ! if ((display_options == dialog_no_display_s && need_ui) || ! display_options == dialog_display_s) ! { ! line_position_t::getline_proc_t getline_proc(new line_position_t::getline_proc_impl_t(boost::bind(&mdi_getline, boost::ref(layout_definition), _1, _2))); ! view.reset(eve_client::make_view( adobe::name_t( "eve definition" ), ! getline_proc, ! layout_definition, ! sheet, ! boost::bind(&mdi_op_callback_t::callback, boost::ref(view_callback), _1, _2), ! size_normal_s, ! default_factory ).release() ); ! view_callback.view_m = view.get(); ! // ! // Set up the view's sheet with display state values, etc. ! // ! for (adobe::dictionary_t::const_iterator first(display_state.begin()), last(display_state.end()); first != last; ++first) ! view->layout_sheet_m.set(first->first, first->second); ! sheet.update(); ! // ! // Show the GUI. ! // ! view->eve_m.evaluate(adobe::eve_t::evaluate_nested); ! view->show_window_m(); #if ADOBE_PLATFORM_MAC ! HIViewRef cntl(adobe::unwrap_display_token<HIViewRef>(view->root_display_m)); ! WindowRef owner(::GetControlOwner(cntl)); ! ::RunAppModalLoopForWindow(owner); #elif ADOBE_PLATFORM_WIN ! MSG msg; ! ! while ( ::GetMessage( &msg, 0, 0, 0 ) ) ! { ! try ! { ! // ! // Push every message through the event_dispatcher, in case it is a keyboard ! // modifier. ! // ! event_dispatcher::keyboard(msg.message, msg.wParam); ! // ! // We always pass every message though to the application anyway. ! // ! TranslateMessage( &msg ); ! DispatchMessage( &msg ); ! } ! catch ( const std::exception& doh ) ! { ! std::cerr << "Exception: " << doh.what() << std::endl; ! } ! catc... [truncated message content] |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:22
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/gil In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources/gil Modified Files: design_guide.dox main.dox tutorial.dox Log Message: asl 1.0.13 Index: main.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/gil/main.dox,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** main.dox 24 Jan 2006 19:38:44 -0000 1.2 --- main.dox 3 Feb 2006 18:33:36 -0000 1.3 *************** *** 3,8 **** \ingroup asl_home \author Lubomir Bourdev and Hailin Jin \n ! Advanced Graphics Technology \n ! Adobe Systems Inc. \section IntroSec Introduction --- 3,8 ---- \ingroup asl_home \author Lubomir Bourdev and Hailin Jin \n ! Advanced Graphics Technology \n ! Adobe Systems Inc. \section IntroSec Introduction *************** *** 12,23 **** \par The library is designed with the following five goals in mind: ! - <b>Generality:</b> Abstracts image representations from algorithms on images. It allows for writing code once and have it work for any image type. ! - <b>Performance:</b> Speed has been instrumental to the design of the library. The generic algorithms provided in the library are comparable in speed to hand-coding the algorithm for a specific image type. ! - <b>Flexibility:</b> Compile-type parameter resolution results in faster code, but severely limits code flexibility. The library allows for any image parameter to be specified at run time (for a minor performance cost comparable to a virtual call overhead). ! - <b>Extensibility:</b> It is easy to extend the library with new color spaces and image types. Library extensions typically require no changes to the library core; at the same time existing image algorithms apply to new color spaces and image types. ! - <b>Compatibility:</b> The library is designed as an STL and Boost complement. Generic STL algorithms can be used for pixel manipulation, and they are especially optimized. The library works with existing raw pixel data from another image library and can even be integrated into a third-party reference counting mechanism. \section ResourcesSec Resources ! - \ref BeforeAfterExample "See the GIL difference!" Example of code before and after GIL. - A Quick, Hands-on \ref GILTutorial "Tutorial". (In <a href="gil_tutorial.pdf">PDF</a>) - A Detailed \ref GILDesignGuide "Design Guide". (In <a href="gil_design_guide.pdf">PDF</a>) --- 12,23 ---- \par The library is designed with the following five goals in mind: ! - <b>Generality:</b> Abstracts image representations from algorithms on images. It allows for writing code once and have it work for any image type. ! - <b>Performance:</b> Speed has been instrumental to the design of the library. The generic algorithms provided in the library are comparable in speed to hand-coding the algorithm for a specific image type. ! - <b>Flexibility:</b> Compile-type parameter resolution results in faster code, but severely limits code flexibility. The library allows for any image parameter to be specified at run time (for a minor performance cost comparable to a virtual call overhead). ! - <b>Extensibility:</b> It is easy to extend the library with new color spaces and image types. Library extensions typically require no changes to the library core; at the same time existing image algorithms apply to new color spaces and image types. ! - <b>Compatibility:</b> The library is designed as an STL and Boost complement. Generic STL algorithms can be used for pixel manipulation, and they are especially optimized. The library works with existing raw pixel data from another image library and can even be integrated into a third-party reference counting mechanism. \section ResourcesSec Resources ! - \ref BeforeAfterExample "See the GIL difference!" Example of code before and after GIL. - A Quick, Hands-on \ref GILTutorial "Tutorial". (In <a href="gil_tutorial.pdf">PDF</a>) - A Detailed \ref GILDesignGuide "Design Guide". (In <a href="gil_design_guide.pdf">PDF</a>) *************** *** 29,87 **** \section AcknowledgementsSec Acknowledgements ! - <b>Jon Brandt</b>, <b>Mark Ruzon</b> and <b>Paul McJones</b> spent significant time reviewing the library and documentation and provided valuable feedback. ! - <b>Alex Stepanov</b>'s class has directly inspired this project. Alex's "start from the inside" and "bottom up" principles have been applied throughout the design. ! - <b>Sean Parent</b> and Alex Stepanov suggested splitting the image into a 'container' and 'range' classes ! - <b>Bjarne Stroustrup</b> reviewed the core library design \section gil_toc GIL Table of Contents ! - \ref GILConcepts ! - \ref PointConcept ! - \ref ChannelConcept ! - \ref ColorSpaceTypeConcept ! - \ref PixelConcept ! - \ref IteratorConcept ! - \ref IteratorAdaptorConcept ! - \ref StepIteratorConcept ! - \ref ImageIteratorConcept ! - \ref LocatorConcept ! - \ref LocatorNDConcept ! - \ref Locator2DConcept ! - \ref XYLocatorConcept ! - \ref ImageViewConcept ! - \ref ImageViewNDConcept ! - \ref ImageView2DConcept ! - \ref GILImageViewConcept ! - \ref ImageConcept ! - \ref ImageNDConcept ! - \ref Image2DConcept ! - \ref GILImageConcept ! - \ref GILModels ! - \ref Channel ! - \ref ColorSpaces ! - \ref CMYK ! - \ref ColorConvert ! - \ref GRAY ! - \ref LAB ! - \ref RGB ! - \ref RGBA ! - \ref Pixel ! - \ref ChannelAccessor ! - \ref ColorBase ! - \ref Iterators ! - \ref PlanarPtr ! - \ref IteratorTraits ! - \ref ByteOperations ! - \ref byte_step ! - \ref byte_distance ! - \ref byte_advance ! - \ref byte_advanced ! - \ref byte_advanced_ref ! - \ref ImageView ! - \ref ImageViewConstructors ! - \ref Image ! - \ref Variant ! - \ref Metafunctions ! - \ref type_factory ! - \ref Algorithms */ --- 29,87 ---- \section AcknowledgementsSec Acknowledgements ! - <b>Jon Brandt</b>, <b>Mark Ruzon</b> and <b>Paul McJones</b> spent significant time reviewing the library and documentation and provided valuable feedback. ! - <b>Alex Stepanov</b>'s class has directly inspired this project. Alex's "start from the inside" and "bottom up" principles have been applied throughout the design. ! - <b>Sean Parent</b> and Alex Stepanov suggested splitting the image into a 'container' and 'range' classes ! - <b>Bjarne Stroustrup</b> reviewed the core library design \section gil_toc GIL Table of Contents ! - \ref GILConcepts ! - \ref PointConcept ! - \ref ChannelConcept ! - \ref ColorSpaceTypeConcept ! - \ref PixelConcept ! - \ref IteratorConcept ! - \ref IteratorAdaptorConcept ! - \ref StepIteratorConcept ! - \ref ImageIteratorConcept ! - \ref LocatorConcept ! - \ref LocatorNDConcept ! - \ref Locator2DConcept ! - \ref XYLocatorConcept ! - \ref ImageViewConcept ! - \ref ImageViewNDConcept ! - \ref ImageView2DConcept ! - \ref GILImageViewConcept ! - \ref ImageConcept ! - \ref ImageNDConcept ! - \ref Image2DConcept ! - \ref GILImageConcept ! - \ref GILModels ! - \ref Channel ! - \ref ColorSpaces ! - \ref CMYK ! - \ref ColorConvert ! - \ref GRAY ! - \ref LAB ! - \ref RGB ! - \ref RGBA ! - \ref Pixel ! - \ref ChannelAccessor ! - \ref ColorBase ! - \ref Iterators ! - \ref PlanarPtr ! - \ref IteratorTraits ! - \ref ByteOperations ! - \ref byte_step ! - \ref byte_distance ! - \ref byte_advance ! - \ref byte_advanced ! - \ref byte_advanced_ref ! - \ref ImageView ! - \ref ImageViewConstructors ! - \ref Image ! - \ref Variant ! - \ref Metafunctions ! - \ref type_factory ! - \ref Algorithms */ *************** *** 89,167 **** /// \ingroup asl_gil /// \brief GIL concept definitions, archetypes and concept checks ! /// @defgroup PointConcept Point ! /// @ingroup GILConcepts ! /// \brief Concept for N-dimensional point and refinement for 2D Ê ! /// @defgroup ChannelConcept Channel ! /// @ingroup GILConcepts ! /// \brief Concept for channel and mutable channel Ê ! /// @defgroup ColorSpaceTypeConcept Color Space ! /// @ingroup GILConcepts ! /// \brief Concept for color space type Ê ! /// @defgroup PixelConcept Pixel ! /// @ingroup GILConcepts ! /// \brief Concept for pixel and mutable pixel Ê ! /// @defgroup IteratorConcept Iterator ! /// @ingroup GILConcepts ! /// \brief Concept for iterators over pixels (fundamental, step, adaptor and image-pixel iterators over immutable/mutable pixels) ! /// @defgroup IteratorAdaptorConcept Iterator Adaptor ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator adaptor over a base iterator Ê ! /// @defgroup StepIteratorConcept Step Iterator ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator that has non-fundamental step Ê ! /// @defgroup ImageIteratorConcept Image Iterator ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator over all pixels in an image Ê ! /// @defgroup LocatorConcept Locator ! /// @ingroup GILConcepts ! /// \brief Concept for locator (generalization of iterator in N-dimensional space) ! /// @defgroup LocatorNDConcept N-Dimensional Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for an N-dimensional locator over immutable/mutable values Ê ! /// @defgroup Locator2DConcept 2-Dimensional Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for a 2-dimensional locator over immutable/mutable values Ê ! /// @defgroup XYLocatorConcept GIL's 2-Dimensional Pixel Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for GIL's 2-dimensional locator over immutable/mutable pixels Ê ! /// @defgroup ImageViewConcept Image View ! /// @ingroup GILConcepts ! /// \brief Concept for image view (N-dimensional range) ! /// @defgroup ImageViewNDConcept N-Dimensional Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for an N-dimensional range over immutable/mutable values Ê ! /// @defgroup ImageView2DConcept 2-Dimensional Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for a 2-dimensional range over immutable/mutable values Ê ! /// @defgroup GILImageViewConcept GIL's 2-Dimensional Pixel Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for GIL's 2-dimensional range over immutable/mutable pixels Ê ! /// @defgroup ImageConcept Image ! /// @ingroup GILConcepts ! /// \brief Concept for image (N-dimensional container) ! /// @defgroup ImageNDConcept N-Dimensional Image ! /// @ingroup ImageConcept ! /// \brief Concept for an N-dimensional container of immutable/mutable values Ê ! /// @defgroup Image2DConcept 2-Dimensional Image ! /// @ingroup ImageConcept ! /// \brief Concept for a 2-dimensional container of immutable/mutable values Ê ! /// @defgroup GILImageConcept GIL's 2-Dimensional Pixel Image ! /// @ingroup ImageConcept ! /// \brief Concept for GIL's 2-dimensional container of immutable/mutable pixels Ê /// @defgroup GILModels GIL Models --- 89,167 ---- /// \ingroup asl_gil /// \brief GIL concept definitions, archetypes and concept checks ! /// @defgroup PointConcept Point ! /// @ingroup GILConcepts ! /// \brief Concept for N-dimensional point and refinement for 2D Ê ! /// @defgroup ChannelConcept Channel ! /// @ingroup GILConcepts ! /// \brief Concept for channel and mutable channel Ê ! /// @defgroup ColorSpaceTypeConcept Color Space ! /// @ingroup GILConcepts ! /// \brief Concept for color space type Ê ! /// @defgroup PixelConcept Pixel ! /// @ingroup GILConcepts ! /// \brief Concept for pixel and mutable pixel Ê ! /// @defgroup IteratorConcept Iterator ! /// @ingroup GILConcepts ! /// \brief Concept for iterators over pixels (fundamental, step, adaptor and image-pixel iterators over immutable/mutable pixels) ! /// @defgroup IteratorAdaptorConcept Iterator Adaptor ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator adaptor over a base iterator Ê ! /// @defgroup StepIteratorConcept Step Iterator ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator that has non-fundamental step Ê ! /// @defgroup ImageIteratorConcept Image Iterator ! /// @ingroup IteratorConcept ! /// \brief Concept for an iterator over all pixels in an image Ê ! /// @defgroup LocatorConcept Locator ! /// @ingroup GILConcepts ! /// \brief Concept for locator (generalization of iterator in N-dimensional space) ! /// @defgroup LocatorNDConcept N-Dimensional Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for an N-dimensional locator over immutable/mutable values Ê ! /// @defgroup Locator2DConcept 2-Dimensional Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for a 2-dimensional locator over immutable/mutable values Ê ! /// @defgroup XYLocatorConcept GIL's 2-Dimensional Pixel Locator ! /// @ingroup LocatorConcept ! /// \brief Concept for GIL's 2-dimensional locator over immutable/mutable pixels Ê ! /// @defgroup ImageViewConcept Image View ! /// @ingroup GILConcepts ! /// \brief Concept for image view (N-dimensional range) ! /// @defgroup ImageViewNDConcept N-Dimensional Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for an N-dimensional range over immutable/mutable values Ê ! /// @defgroup ImageView2DConcept 2-Dimensional Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for a 2-dimensional range over immutable/mutable values Ê ! /// @defgroup GILImageViewConcept GIL's 2-Dimensional Pixel Image View ! /// @ingroup ImageViewConcept ! /// \brief Concept for GIL's 2-dimensional range over immutable/mutable pixels Ê ! /// @defgroup ImageConcept Image ! /// @ingroup GILConcepts ! /// \brief Concept for image (N-dimensional container) ! /// @defgroup ImageNDConcept N-Dimensional Image ! /// @ingroup ImageConcept ! /// \brief Concept for an N-dimensional container of immutable/mutable values Ê ! /// @defgroup Image2DConcept 2-Dimensional Image ! /// @ingroup ImageConcept ! /// \brief Concept for a 2-dimensional container of immutable/mutable values Ê ! /// @defgroup GILImageConcept GIL's 2-Dimensional Pixel Image ! /// @ingroup ImageConcept ! /// \brief Concept for GIL's 2-dimensional container of immutable/mutable pixels Ê /// @defgroup GILModels GIL Models *************** *** 169,251 **** /// \brief Standard models of GIL concepts Ê ! /// @defgroup Channel Channel ! /// @ingroup GILModels ! /// \brief Channel and channel operations Ê ! /// @defgroup ColorSpaces Color Space ! /// @ingroup GILModels ! /// \brief Color spaces and color space conversion Ê ! /// @defgroup Pixel Pixel ! /// @ingroup GILModels ! /// \brief Pixel and pixel-related functions ÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊ ! /// @defgroup ChannelAccessor Channel Accessor ! /// @ingroup Pixel ! /// \brief Classes allowing accessing a channel of a pixel Ê ! /// @defgroup ColorBase Color Bases ! /// @ingroup Pixel ! /// \brief A bundle of channel values/references/pointers of a given color space Ê ! /// @defgroup Iterators Pixel Iterators ! /// @ingroup GILModels ! /// \brief Iterators operating on pixels Ê ! /// @defgroup PlanarPtr Planar Pointers ! /// @ingroup Iterators ! /// \brief Implementations of pointers to planar pixels Ê ! /// @defgroup IteratorTraits Iterator Traits ! /// @ingroup Iterators ! /// \brief Traits for pixel iterators Ê ! /// @defgroup ByteOperations Byte-level operations ! /// @ingroup Iterators ! /// \brief Byte-level operations on pixel iterators Ê ! /// @defgroup byte_step byte_step ! /// @ingroup ByteOperations ! /// \brief returns the number of bytes from the current pixel of a pointer to the next Ê ! /// @defgroup byte_distance byte_distance ! /// @ingroup ByteOperations ! /// \brief Returns the distance in bytes from the first pixel iterator to the second Ê ! /// @defgroup byte_advance byte_advance ! /// @ingroup ByteOperations ! /// \brief Moves a pixel iterator a given distance in bytes Ê ! /// @defgroup byte_advanced byte_advanced ! /// @ingroup ByteOperations ! /// \brief Returns a pixel iterator a given byte distance away from a given pixel iterator Ê ! /// @defgroup byte_advanced_ref byte_advanced_ref ! /// @ingroup ByteOperations ! /// \brief Shortcut to advancing a pixel iterator by a given number of bytes and taking the reference in case the compiler is not smart enough Ê ! /// \defgroup ImageView Image View ! /// @ingroup GILModels ! /// \brief Image views and related operations Ê ! /// @defgroup ImageViewConstructors Image View Constructors ! /// @ingroup ImageView ! /// \brief Methods for constructing image views from raw data or other image views Ê ! /// \defgroup Image Image ! /// @ingroup GILModels ! /// \brief Images and related operations Ê ! /// @defgroup Variant Variant ! /// @ingroup GILModels ! /// \brief Support for concepts with run-time instantiation. Used in GIL to provide images and image views of run-time specified color space, channel depth, etc. Ê ! /// @defgroup Metafunctions Meta-functions ! /// @ingroup GILModels ! /// \brief Meta-functions that construct types or return type properties Ê ! /// @defgroup Algorithms Algorithms ! /// @ingroup GILModels ! /// \brief Some basic STL-style algorithms when applied to images (as opposed to ranges) Ê /// \brief namespace for functions not directly needed by the client --- 169,251 ---- /// \brief Standard models of GIL concepts Ê ! /// @defgroup Channel Channel ! /// @ingroup GILModels ! /// \brief Channel and channel operations Ê ! /// @defgroup ColorSpaces Color Space ! /// @ingroup GILModels ! /// \brief Color spaces and color space conversion Ê ! /// @defgroup Pixel Pixel ! /// @ingroup GILModels ! /// \brief Pixel and pixel-related functions ÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊÊ ! /// @defgroup ChannelAccessor Channel Accessor ! /// @ingroup Pixel ! /// \brief Classes allowing accessing a channel of a pixel Ê ! /// @defgroup ColorBase Color Bases ! /// @ingroup Pixel ! /// \brief A bundle of channel values/references/pointers of a given color space Ê ! /// @defgroup Iterators Pixel Iterators ! /// @ingroup GILModels ! /// \brief Iterators operating on pixels Ê ! /// @defgroup PlanarPtr Planar Pointers ! /// @ingroup Iterators ! /// \brief Implementations of pointers to planar pixels Ê ! /// @defgroup IteratorTraits Iterator Traits ! /// @ingroup Iterators ! /// \brief Traits for pixel iterators Ê ! /// @defgroup ByteOperations Byte-level operations ! /// @ingroup Iterators ! /// \brief Byte-level operations on pixel iterators Ê ! /// @defgroup byte_step byte_step ! /// @ingroup ByteOperations ! /// \brief returns the number of bytes from the current pixel of a pointer to the next Ê ! /// @defgroup byte_distance byte_distance ! /// @ingroup ByteOperations ! /// \brief Returns the distance in bytes from the first pixel iterator to the second Ê ! /// @defgroup byte_advance byte_advance ! /// @ingroup ByteOperations ! /// \brief Moves a pixel iterator a given distance in bytes Ê ! /// @defgroup byte_advanced byte_advanced ! /// @ingroup ByteOperations ! /// \brief Returns a pixel iterator a given byte distance away from a given pixel iterator Ê ! /// @defgroup byte_advanced_ref byte_advanced_ref ! /// @ingroup ByteOperations ! /// \brief Shortcut to advancing a pixel iterator by a given number of bytes and taking the reference in case the compiler is not smart enough Ê ! /// \defgroup ImageView Image View ! /// @ingroup GILModels ! /// \brief Image views and related operations Ê ! /// @defgroup ImageViewConstructors Image View Constructors ! /// @ingroup ImageView ! /// \brief Methods for constructing image views from raw data or other image views Ê ! /// \defgroup Image Image ! /// @ingroup GILModels ! /// \brief Images and related operations Ê ! /// @defgroup Variant Variant ! /// @ingroup GILModels ! /// \brief Support for concepts with run-time instantiation. Used in GIL to provide images and image views of run-time specified color space, channel depth, etc. Ê ! /// @defgroup Metafunctions Meta-functions ! /// @ingroup GILModels ! /// \brief Meta-functions that construct types or return type properties Ê ! /// @defgroup Algorithms Algorithms ! /// @ingroup GILModels ! /// \brief Some basic STL-style algorithms when applied to images (as opposed to ranges) Ê /// \brief namespace for functions not directly needed by the client Index: tutorial.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/gil/tutorial.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** tutorial.dox 24 Jan 2006 19:38:44 -0000 1.1 --- tutorial.dox 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 1,7 **** //////////////////////////////////////////////////////////////////////////////////////// ! /// \file /// \brief Doxygen documentation /// \author Lubomir Bourdev and Hailin Jin \n ! /// Adobe Systems Incorporated /// /// --- 1,7 ---- //////////////////////////////////////////////////////////////////////////////////////// ! /// \file /// \brief Doxygen documentation /// \author Lubomir Bourdev and Hailin Jin \n ! /// Adobe Systems Incorporated /// /// *************** *** 24,47 **** - \ref InstallSec - \ref ObjectsSec ! - \ref UsefulTypedefs ! - \ref GenericObjects ! - \ref RelatedTypes - \ref ImageAndViewSec ! - \ref ImageSec ! - \ref ImageViewSec ! - \ref ImageViewFactory - \ref ManipulatingImages ! - \ref ContextIndepdendentPixOp ! - \ref GenericAndSpecialized ! - \ref ContextAwareOperations - \ref VariantSec - \ref ExtendingGIL - \ref CodeExamples ! - \ref HistogramExample ! - \ref SafeAreaExample ! - \ref GDIExample ! \section InstallSec Installation GIL is part of Adobe Software Library (ASL) which can be installed at http://opensource.adobe.com. --- 24,47 ---- - \ref InstallSec - \ref ObjectsSec ! - \ref UsefulTypedefs ! - \ref GenericObjects ! - \ref RelatedTypes - \ref ImageAndViewSec ! - \ref ImageSec ! - \ref ImageViewSec ! - \ref ImageViewFactory - \ref ManipulatingImages ! - \ref ContextIndepdendentPixOp ! - \ref GenericAndSpecialized ! - \ref ContextAwareOperations - \ref VariantSec - \ref ExtendingGIL - \ref CodeExamples ! - \ref HistogramExample ! - \ref SafeAreaExample ! - \ref GDIExample ! \section InstallSec Installation GIL is part of Adobe Software Library (ASL) which can be installed at http://opensource.adobe.com. *************** *** 49,53 **** There is no library to link against. Including \p image_view_factory.hpp will be sufficient for most projects. ! \section ObjectsSec Basic Concepts <i>Pixels</i> are the fundamental building blocks of images. A pixel is a sequence of channels whose number and interpretation are defined by a color space. --- 49,53 ---- There is no library to link against. Including \p image_view_factory.hpp will be sufficient for most projects. ! \section ObjectsSec Basic Concepts <i>Pixels</i> are the fundamental building blocks of images. A pixel is a sequence of channels whose number and interpretation are defined by a color space. *************** *** 109,113 **** template <typename T, typename C> struct iterator_traits<pixel<T,C>*> { ! typedef random_access_iterator_tag iterator_category; typedef pixel<T,C> value_type; typedef ptrdiff_t difference_type; --- 109,113 ---- template <typename T, typename C> struct iterator_traits<pixel<T,C>*> { ! typedef random_access_iterator_tag iterator_category; typedef pixel<T,C> value_type; typedef ptrdiff_t difference_type; *************** *** 169,173 **** \code ! template <typename IMG> // Models GIL Image void my_const_test(const IMG& img) { // IMG::view_type v=view(img); // Error: can't get non-const view from const image --- 169,173 ---- \code ! template <typename IMG> // Models GIL Image void my_const_test(const IMG& img) { // IMG::view_type v=view(img); // Error: can't get non-const view from const image *************** *** 250,254 **** \code ! rgb16_image img(100,100); // an RGB interleaved image // grayscale view over the green (index 1) channel of img --- 250,254 ---- \code ! rgb16_image img(100,100); // an RGB interleaved image // grayscale view over the green (index 1) channel of img *************** *** 284,288 **** void make_red(const VIEW& img) { typename VIEW::value_type red; ! color_convert(rgb8_pixel(255,0,0), red); // convert to red in the image color space and bit depth for (typename VIEW::iterator it=img.begin(); it!=img.end(); ++it) *it=red; --- 284,288 ---- void make_red(const VIEW& img) { typename VIEW::value_type red; ! color_convert(rgb8_pixel(255,0,0), red); // convert to red in the image color space and bit depth for (typename VIEW::iterator it=img.begin(); it!=img.end(); ++it) *it=red; Index: design_guide.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/gil/design_guide.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** design_guide.dox 24 Jan 2006 19:38:44 -0000 1.1 --- design_guide.dox 3 Feb 2006 18:33:36 -0000 1.2 *************** *** 175,179 **** // the type of coordinate along each axis template <size_t D> struct axis { typedef ... coord_type; }; ! static const size_t num_dimensions=...; --- 175,179 ---- // the type of coordinate along each axis template <size_t D> struct axis { typedef ... coord_type; }; ! static const size_t num_dimensions=...; *************** *** 611,615 **** \code namespace std { ! template <typename IT> // Models PixelIterator struct iterator_traits { typedef random_access_iterator_tag iterator_category; --- 611,615 ---- \code namespace std { ! template <typename IT> // Models PixelIterator struct iterator_traits { typedef random_access_iterator_tag iterator_category; |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:21
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/mac In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets/headers/mac Modified Files: carbon_safe.hpp metrics.hpp ui_core_implementation.hpp Added Files: metric_extractor.hpp os_utilities.hpp Log Message: asl 1.0.13 Index: carbon_safe.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/mac/carbon_safe.hpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** carbon_safe.hpp 6 Jan 2006 18:02:58 -0000 1.4 --- carbon_safe.hpp 3 Feb 2006 18:33:36 -0000 1.5 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 20,24 **** #ifdef __MWERKS__ ! #pragma warn_implicitconv off #endif --- 20,24 ---- #ifdef __MWERKS__ ! #pragma warn_implicitconv off #endif *************** *** 26,42 **** #ifdef __MWERKS__ ! #pragma warn_implicitconv reset #endif /* ! REVISIT (sparent) : Apple insists that you include the entire Carbon/Carbon.h framework to ! use any of Carbon. This header file #defines check which conflicts with boost. The work- ! around is to undef check here. ! ! (In an unbelieveable set of circumstances, I wrote the check macro!) */ #ifdef check ! #undef check #endif --- 26,42 ---- #ifdef __MWERKS__ ! #pragma warn_implicitconv reset #endif /* ! REVISIT (sparent) : Apple insists that you include the entire Carbon/Carbon.h framework to ! use any of Carbon. This header file #defines check which conflicts with boost. The work- ! around is to undef check here. ! ! (In an unbelieveable set of circumstances, I wrote the check macro!) */ #ifdef check ! #undef check #endif *************** *** 50,95 **** { public: ! os_exception(long status, const char* file, long line) throw() ! { ! try ! { ! std::stringstream t; ! t << status; ! format(t.str().c_str(), file, line); ! } ! catch (...) ! { } ! } ! os_exception(const char* status, const char* file, long line) throw() ! { ! format(status, file, line); ! } ! os_exception(const std::string& status, const char* file, long line) throw() ! { ! format(status.c_str(), file, line); ! } ! ~os_exception() throw() {} ! const char* what () const throw() ! { return what_m.c_str(); } private: ! void format(const char* status, const char* file, long line) ! { ! try ! { ! std::stringstream t; ! t << "Error: " << status << " (" << file << ", line " << line << ")"; ! what_m.assign(t.str()); ! } ! catch (...) ! { } ! } ! std::string what_m; }; --- 50,95 ---- { public: ! os_exception(long status, const char* file, long line) throw() ! { ! try ! { ! std::stringstream t; ! t << status; ! format(t.str().c_str(), file, line); ! } ! catch (...) ! { } ! } ! os_exception(const char* status, const char* file, long line) throw() ! { ! format(status, file, line); ! } ! os_exception(const std::string& status, const char* file, long line) throw() ! { ! format(status.c_str(), file, line); ! } ! ~os_exception() throw() {} ! const char* what () const throw() ! { return what_m.c_str(); } private: ! void format(const char* status, const char* file, long line) ! { ! try ! { ! std::stringstream t; ! t << "Error: " << status << " (" << file << ", line " << line << ")"; ! what_m.assign(t.str()); ! } ! catch (...) ! { } ! } ! std::string what_m; }; *************** *** 101,120 **** // REVISIT (fbrereto) : Turn this back on when we have an interface to handle ! // errors on the callback side of the OS event loop #if 0 inline void ADOBE_REQUIRE_STATUS_impl(long status, char* file, long line) { ! if (status != 0) throw adobe::os_exception(status, file, line); } #else inline void ADOBE_REQUIRE_STATUS_impl(long status, char*, long) { ! if (status != 0) ::SysBeep(10); } #endif /*************************************************************************************************/ ! #define ADOBE_REQUIRE_STATUS(x) adobe::implementation::ADOBE_REQUIRE_STATUS_impl((x), __FILE__, __LINE__) /****************************************************************************************************/ --- 101,120 ---- // REVISIT (fbrereto) : Turn this back on when we have an interface to handle ! // errors on the callback side of the OS event loop #if 0 inline void ADOBE_REQUIRE_STATUS_impl(long status, char* file, long line) { ! if (status != 0) throw adobe::os_exception(status, file, line); } #else inline void ADOBE_REQUIRE_STATUS_impl(long status, char*, long) { ! if (status != 0) ::SysBeep(10); } #endif /*************************************************************************************************/ ! #define ADOBE_REQUIRE_STATUS(x) adobe::implementation::ADOBE_REQUIRE_STATUS_impl((x), __FILE__, __LINE__) /****************************************************************************************************/ Index: metrics.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/mac/metrics.hpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** metrics.hpp 6 Jan 2006 18:02:58 -0000 1.4 --- metrics.hpp 3 Feb 2006 18:33:36 -0000 1.5 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 24,28 **** /****************************************************************************************************/ ! adobe::dictionary_t widget_metrics(const std::string& xstr, const adobe::dictionary_t& context); /****************************************************************************************************/ --- 24,29 ---- /****************************************************************************************************/ ! adobe::dictionary_t widget_metrics( const std::string& xstr, ! const adobe::dictionary_t& context = adobe::dictionary_t()); /****************************************************************************************************/ --- NEW FILE: metric_extractor.hpp --- /* Copyright 2005-2006 Adobe Systems Incorporated Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ #ifndef ADOBE_METRICS_EXTRACTOR_MAC_HPP #define ADOBE_METRICS_EXTRACTOR_MAC_HPP /****************************************************************************************************/ #include <adobe/config.hpp> #include <adobe/dictionary_fwd.hpp> /****************************************************************************************************/ namespace adobe { /****************************************************************************************************/ /*! \defgroup widget_metrics_mac Mac Widget Metrics \ingroup widget_lib \section widget_metrics_mac_parameters Parameters The following is a list of metrics one can supply for a widget on the Mac. All values are in unit pixels. All values default to 0. <table width="100%" border="1"> <tr><th width="10%">Name</th><th width="30%">Structure</th><th>Notes</th></tr> <tr> <td><code>size</code></td> <td><code>[ width, height ]</code></td> <td>Base size of the widget</td> </tr> <tr> <td><code>adjust_position</code></td> <td><code>[ left, top ]</code></td> <td>Number of pixels to push the widget. Positive values move the widget away from the origin of the window.</td> </tr> <tr> <td><code>adjust_size</code></td> <td><code>[ width, height ]</code></td> <td>Adjustments made to the base size of the widget. The adjusted size is passed to the OS so the resulting widget is the base size originally intended.</td> </tr> <tr> <td><code>adjust_baseline</code></td> <td><code>value</code></td> <td>Adjustment of the baseline. Positive values move the baseline away from the origin of the window.</td> </tr> <tr> <td><code>outset</code></td> <td><code>[ left, top, right, bottom ]</code></td> <td>Amount of outset for a given edge of the widget. These amounts affect the base size and position of the widget when the bounds of the widget are set. See \ref widget_metrics_mac_pipeline_placement.</td> </tr> <tr> <td><code>frame</code></td> <td><code>[ left, top, right, bottom ]</code></td> <td>Amount of frame for a given edge of the widget.</td> </tr> <tr> <td><code>inset</code></td> <td><code>[ left, top, right, bottom ]</code></td> <td>Amount of inset for a given edge of the widget.</td> </tr> <tr> <td><code>spacing</code></td> <td><code>value</code></td> <td>If there is text in the widget, this is the spacing needed between the widget's visual element and the text for the widget. Example: <code>check_box</code> has a nonzero spacing, but <code>button</code> has a spacing of 0 (because the text overlays the visual element).</td> </tr> </table> \section widget_metrics_mac_pipelines Metrics Pipelines \subsection widget_metrics_mac_pipeline_measurement Measurement Pipeline -# All the possible text strings for the widget are measured. The largest width, height and baseline are preserved on a per-element basis (i.e., it is possible for one piece of text to contribute the max width and another to contribute the max height) -# The base height of the widget is set to <code>size.height - adjust_size.height</code> -# The base width of the widget is set to <code>size.width - adjust_size.width</code> -# If text width is nonzero then <code>text_width + spacing</code> is added to the base width of the widget -# If there is a valid text baseline value the baseline of the result is set to <code>text_baseline + adjust_baseline</code> -# The <code>outset.left</code> is added to the resultant left outset -# The <code>outset.left + outset.right</code> is <i>subtracted</i> from the resultant right outset -# The <code>outset.top</code> is added to the resultant top outset -# The <code>outset.top + outset.bottom</code> is <i>subtracted</i> from the resultant bottom outset -# Resultant frame is set from <code>frame</code> -# Resultant inset is set from <code>inset</code> -# The resultant extents is returned \subsection widget_metrics_mac_pipeline_placement Placement Pipeline -# <code>adjust_position.left - extents.outset.left</code> is added to the left position of the widget -# <code>adjust_position.top - extents.outset.top</code> is added to the top position of the widget -# The height of the widget is increased by <code>adjust_size.height + extents.outset.top + extents.outset.bottom</code> -# The width of the widget is increased by <code>adjust_size.width + extents.outset.left + extents.outset.right</code> -# The bounds of the widget are set */ /*! \ingroup widget_lib \brief Utility class to access widget metrics for the Macintosh. metric_extractor_t is a struct that allows for easy access to the metrics found in a parsed and evaluated xstr definition from the mac metrics library. See \ref widget_metrics_mac for more information on the dictionary format describing the metrics for a given widget. */ struct metric_extractor_t { /// indices used to access elements for a compound (array-based) metric enum array_index_t { /// first element index_left = 0, /// second element index_top = 1, /// third element index_right = 2, /// fourth element index_bottom = 3, /// same as index_left index_width = index_left, /// same as index_top index_height = index_top }; /// \param dictionary the dictionary containing the widget metrics. /// Internally the dictionary is stored by value. explicit metric_extractor_t(const adobe::dictionary_t& dictionary = adobe::dictionary_t()) : dictionary_m(dictionary) { } /// Obtains a singleton metric /// \param tag the name of the metric we are interested in getting /// \return the value of the metric; 0 if the metric does not exist long operator () (const name_t& tag) const { long result(0); dictionary_m.get(tag, result); return result; } /// Obtains a singleton metric from a compound (array-based) metric /// \param tag the name of the metric we are interested in getting /// \param index the index inside the compound metric to fetch /// \return the value of the metric; 0 if the metric does not exist long operator () (const name_t& tag, array_index_t index) const { adobe::array_t array_result; long result(0); dictionary_m.get(tag, array_result); array_result.get(std::size_t(index), result); return result; } /// If this extractor hasn't been setup yet then this function returns /// true, otherwise it returns false. /// \return does this extractor have metrics available. bool empty() const { return dictionary_m.empty(); } private: adobe::dictionary_t dictionary_m; }; /****************************************************************************************************/ } /****************************************************************************************************/ #endif /****************************************************************************************************/ Index: ui_core_implementation.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/headers/mac/ui_core_implementation.hpp,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** ui_core_implementation.hpp 24 Jan 2006 19:38:46 -0000 1.7 --- ui_core_implementation.hpp 3 Feb 2006 18:33:36 -0000 1.8 *************** *** 1,11 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ ! #ifndef ADOBE_UI_CORE_IMPLEMENTATION_HPP #define ADOBE_UI_CORE_IMPLEMENTATION_HPP [...1782 lines suppressed...] /****************************************************************************************************/ + /****************************************************************************************************/ + /****************************************************************************************************/ + /****************************************************************************************************/ + /****************************************************************************************************/ + /****************************************************************************************************/ + /****************************************************************************************************/ ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::window_t::implementation_t); ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::group_t::implementation_t); ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::tab_group_t::implementation_t); *************** *** 811,815 **** ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::unit_edit_text_t::implementation_t); ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::slider_t::implementation_t); - ADOBE_SERIALIZABLE_EQUALITY_COMPARABLE_BOILERPLATE_DECLARATION(adobe::bevel_button_t::implementation_t); /****************************************************************************************************/ --- 1044,1047 ---- --- NEW FILE: os_utilities.hpp --- /* Copyright 2005-2006 Adobe Systems Incorporated Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt or a copy at http://opensource.adobe.com/licenses.html) */ /****************************************************************************************************/ #ifndef ADOBE_UI_CORE_OS_UTILITIES_HPP #define ADOBE_UI_CORE_OS_UTILITIES_HPP /****************************************************************************************************/ #include <adobe/config.hpp> #include <adobe/istream.hpp> #include <adobe/future/memory.hpp> #include <adobe/unicode.hpp> #include "carbon_safe.hpp" #include "ui_core.hpp" #include "ui_core_common.hpp" #include "metrics.hpp" #include "metric_extractor.hpp" #include <boost/noncopyable.hpp> #include <stdexcept> /****************************************************************************************************/ inline bool operator == (const ::EventTypeSpec& x, const ::EventTypeSpec& y) { return x.eventClass == y.eventClass && x.eventKind == y.eventKind; } /****************************************************************************************************/ namespace adobe { /****************************************************************************************************/ #define ADOBE_DELETE_PTR_SPECIALIZATION(type, func) \ template<> \ struct delete_ptr<type> \ { \ void operator()(type x) const \ { if (x) func(x); } \ }; /****************************************************************************************************/ //ADOBE_DELETE_PTR_SPECIALIZATION(::CGrafPtr, ::DisposePort) //ADOBE_DELETE_PTR_SPECIALIZATION(::MouseTrackingRef, ::ReleaseMouseTrackingRegion) //ADOBE_DELETE_PTR_SPECIALIZATION(::RgnHandle, ::DisposeRgn) ADOBE_DELETE_PTR_SPECIALIZATION(::ATSUStyle, ::ATSUDisposeStyle) ADOBE_DELETE_PTR_SPECIALIZATION(::ATSUTextLayout, ::ATSUDisposeTextLayout) ADOBE_DELETE_PTR_SPECIALIZATION(::CFBundleRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CFLocaleRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CFMutableDictionaryRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CFNumberFormatterRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CFStringRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CFURLRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CGDataProviderRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::CGImageRef, ::CFRelease) ADOBE_DELETE_PTR_SPECIALIZATION(::ControlEditTextValidationUPP, ::DisposeControlEditTextValidationUPP) ADOBE_DELETE_PTR_SPECIALIZATION(::EventHandlerRef, ::RemoveEventHandler) ADOBE_DELETE_PTR_SPECIALIZATION(::EventHandlerUPP, ::DisposeEventHandlerUPP) ADOBE_DELETE_PTR_SPECIALIZATION(::EventLoopTimerRef, ::RemoveEventLoopTimer) ADOBE_DELETE_PTR_SPECIALIZATION(::Handle, ::DisposeHandle) ADOBE_DELETE_PTR_SPECIALIZATION(::WindowRef, ::ReleaseWindow) /****************************************************************************************************/ namespace implementation { /****************************************************************************************************/ extern adobe::static_name_t k_attribute_theme; extern adobe::static_name_t k_attribute_theme_large; extern adobe::static_name_t k_attribute_theme_normal; extern adobe::static_name_t k_attribute_theme_small; extern adobe::static_name_t k_attribute_theme_mini; extern adobe::static_name_t k_metric_gap; extern adobe::static_name_t k_metric_size; extern adobe::static_name_t k_metric_adjust_position; extern adobe::static_name_t k_metric_adjust_size; extern adobe::static_name_t k_metric_adjust_baseline; extern adobe::static_name_t k_metric_outset; extern adobe::static_name_t k_metric_frame; extern adobe::static_name_t k_metric_inset; extern adobe::static_name_t k_metric_spacing; /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ std::string cfstring_to_string(::CFStringRef x); /****************************************************************************************************/ inline std::string cfstring_to_string(const adobe::auto_resource< ::CFStringRef >& x) { return cfstring_to_string(x.get()); } /****************************************************************************************************/ inline adobe::auto_resource< ::CFStringRef > string_to_cfstring(const std::string& x) { adobe::auto_resource< ::CFStringRef > converted(::CFStringCreateWithCString( NULL, x.c_str(), kCFStringEncodingUTF8)); return converted; } /****************************************************************************************************/ inline adobe::auto_resource< ::CFStringRef > localize_to_cfstring(const std::string& x) { return string_to_cfstring(adobe::localize(x)); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename T> struct event_param_type; template <> struct event_param_type< ::UInt32 > { static const ::EventParamType value = typeUInt32; }; template <> struct event_param_type< ::HICommand > { static const ::EventParamType value = typeHICommand; }; template <> struct event_param_type< ::ControlPartCode > { static const ::EventParamType value = typeControlPartCode; }; /****************************************************************************************************/ template < ::EventParamName name, typename T> void get_event_parameter(::EventRef the_event, T& value) { ::EventParamType actual_type; ::UInt32 actual_size; ::ADOBE_REQUIRE_STATUS(::GetEventParameter( the_event, name, event_param_type<T>::value, &actual_type, sizeof(T), &actual_size, &value)); if (actual_type != event_param_type<T>::value) throw std::runtime_error("get_event_parameter differing types"); if (actual_size != sizeof(T)) throw std::runtime_error("get_event_parameter differing sizes"); } /****************************************************************************************************/ template <typename T> bool get_widget_data(::ControlRef widget, ::ControlPartCode part, ::ResType tag, T& data, bool throwing = true) { ::Size t_size(sizeof(T)); ::Size actual_size(0); ::OSStatus result(::GetControlData(widget, part, tag, t_size, &data, &actual_size)); if (!throwing) return result == noErr; ::ADOBE_REQUIRE_STATUS(result); assert(t_size == actual_size); return true; } /****************************************************************************************************/ inline unsigned long get_current_tick_time() { return ::EventTimeToTicks(::GetLastUserEventTime()); } /****************************************************************************************************/ template <typename Widget> inline boost::uint32_t get_value(const Widget& widget) { return get_value< ::ControlRef >(widget.control_m); } /****************************************************************************************************/ template <> inline boost::uint32_t get_value< ::ControlRef >(const ::ControlRef& control) { if (!control) return 0; return ::GetControl32BitValue(control); } /****************************************************************************************************/ template <typename T> void get_bounds(const T& widget, ::Rect& bounds, bool absolute = false); /****************************************************************************************************/ template <> void get_bounds< ::ControlRef >(const ::ControlRef& control, ::Rect& bounds, bool absolute); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /// The field text is text that relates to (e.g. a popup) or is (e.g. an edit text) the value of the /// widget. This is different from the label, as the field text corresponds directly to the value this /// widget helps manage. If a widget has no field text (e.g. a checkbox) this function is undefined. template <typename T> std::string get_field_text(T&); /****************************************************************************************************/ template <> std::string get_field_text< ::ControlRef >(::ControlRef& control); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ std::string get_name(const ::ControlRef& control); /****************************************************************************************************/ std::string get_name(const ::WindowRef& window); /****************************************************************************************************/ /// The name is text that decorates the widget, but is not related to the value of the /// widget itself. For widgets that have no extra-text decorations, this function is undefined. /// Note that a static text widget is a name by definition. template <typename Widget> std::string get_name(const Widget& widget) { return get_name(widget.control_m); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ inline ::ATSUFontID get_atsui_font_id(const char* font_name, std::size_t name_length) { ::ATSUFontID atsui_font_id; ::ADOBE_REQUIRE_STATUS(::ATSUFindFontFromName( font_name, name_length, static_cast<unsigned long>(kFontNoName), kFontNoPlatformCode, kFontNoScriptCode, kFontNoLanguageCode, &atsui_font_id)); return atsui_font_id; } /****************************************************************************************************/ inline ::ATSUFontID get_atsui_font_id(const char* font_name) { return get_atsui_font_id(font_name, std::strlen(font_name)); } /****************************************************************************************************/ ::FMFontFamily get_classic_font_id(const char* font_name, std::size_t name_length); /****************************************************************************************************/ inline ::FMFontFamily get_classic_font_id(const char* font_name) { return get_classic_font_id(font_name, std::strlen(font_name)); } /****************************************************************************************************/ inline ::FMFontFamily get_classic_font_id(Str255 font_name) { const char* first(reinterpret_cast<char*>(&font_name[1])); const char* last(first + font_name[0]); std::string font_name_c(first, last); return get_classic_font_id(font_name_c.c_str(), font_name_c.size()); } /****************************************************************************************************/ inline ::ThemeFontID theme_to_ThemeFontID(const adobe::theme_t& style) { adobe::theme_t masked(style & adobe::theme_mask_s); ::ThemeFontID font_id(kThemeSystemFont); switch (masked) { case adobe::theme_mini_s: font_id = kThemeMiniSystemFont; break; case adobe::theme_small_s: font_id = kThemeSmallSystemFont; break; case adobe::theme_large_s: case adobe::theme_normal_s: default: font_id = kThemeSystemFont; break; } return font_id; } /****************************************************************************************************/ template <typename T> void atsu_set_attribute(::ATSUStyle style, ::ATSUAttributeTag tag, T value) { ::ByteCount size = sizeof(value); ::ATSUAttributeValuePtr ptr = &value; ADOBE_REQUIRE_STATUS(::ATSUSetAttributes(style, 1, &tag, &size, &ptr)); } /****************************************************************************************************/ adobe::extents_t get_text_dimensions(const std::string& text, adobe::theme_t theme); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ void theme_to_rec(const adobe::theme_t& style, ControlFontStyleRec& style_rec); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename T> bool set_widget_data(::ControlRef widget, ::ControlPartCode part, ::ResType tag, const T& data, bool throwing = true) { ::OSStatus result(::SetControlData(widget, part, tag, sizeof(T), &data)); if (!throwing) return result == noErr; ::ADOBE_REQUIRE_STATUS(result); return true; } /****************************************************************************************************/ void set_popup_with_text(ControlRef control, const std::string& text, unsigned long cur_time); /****************************************************************************************************/ /// selects the text within a widget from [ start_pos, end_pos ] (note: inclusive end!) template <typename T> void set_selection(T& control, std::size_t start_pos, std::size_t end_pos); /****************************************************************************************************/ template <> inline void set_selection< ::TXNObject >( ::TXNObject& control, std::size_t start_pos, std::size_t end_pos) { ::ADOBE_REQUIRE_STATUS(::TXNSetSelection(control, start_pos, end_pos)); } /****************************************************************************************************/ template <typename Widget> void set_focus(Widget& widget, bool make_focused) { set_focus< ::ControlRef >(widget.control_m, make_focused); } /****************************************************************************************************/ template <> void set_focus< ::ControlRef >(::ControlRef& control, bool make_focused); /****************************************************************************************************/ template <typename T> void set_refresh(T& widget); /****************************************************************************************************/ template <> inline void set_refresh< ::ControlRef >(::ControlRef& control) { assert(control); ADOBE_REQUIRE_STATUS(::HIViewSetNeedsDisplay(control, true)); } /****************************************************************************************************/ void set_bounds(::ControlRef control, const ::Rect& new_bounds); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename Widget> inline const std::string& widget_tag(const Widget&) { static const std::string value_s("<xstr id='metric_unknown'/>{ }</xstr>"); return value_s; } template <typename Widget> inline adobe::dictionary_t extra_widget_context(const Widget&) { return adobe::dictionary_t(); } #define ADOBE_WIDGET_TAG_BOILERPLATE(widgettype, static_tag) \ namespace implementation { \ template <> inline const std::string& widget_tag< widgettype >(const widgettype&) \ { static const std::string value_s(static_tag); return value_s; } \ } // namespace implementation /****************************************************************************************************/ inline adobe::dictionary_t dictionary_union(const adobe::dictionary_t& src1, const adobe::dictionary_t& src2) { if (src1.empty()) return src2; else if (src2.empty()) return src1; adobe::dictionary_t dst; adobe::set_union(src1, src2, dst.inserter(), adobe::compare_members(&adobe::dictionary_t::value_type::first)); return dst; } /****************************************************************************************************/ template <typename Widget> void set_metric_extractor(Widget& w) { // REVISIT (fbrereto) : If metrics can be changed at runtime for this // widget specifically this shortcut will have to go. if (!w.metrics_m.empty()) return; adobe::static_name_t attribute_theme_value("unknown"); adobe::dictionary_t context; switch (w.theme_m & adobe::theme_mask_s) { case adobe::theme_large_s: attribute_theme_value = k_attribute_theme_large; break; case adobe::theme_normal_s: attribute_theme_value = k_attribute_theme_normal; break; case adobe::theme_small_s: attribute_theme_value = k_attribute_theme_small; break; case adobe::theme_mini_s: attribute_theme_value = k_attribute_theme_mini; break; default: break; } adobe::dictionary_t::write_reference context_write(context.write()); context_write[k_attribute_theme] = adobe::value_t(attribute_theme_value); w.metrics_m = adobe::metric_extractor_t(widget_metrics(widget_tag(w), dictionary_union(extra_widget_context(w), context))); } /****************************************************************************************************/ template <typename Widget> void shed_fudges(const Widget& control, adobe::point_2d_t& position, adobe::extents_t& extents) { extents.height() += control.metrics_m(k_metric_adjust_size, adobe::metric_extractor_t::index_height); extents.width() += control.metrics_m(k_metric_adjust_size, adobe::metric_extractor_t::index_width); long fudge_left(control.metrics_m(k_metric_adjust_position, adobe::metric_extractor_t::index_left)); long fudge_top(control.metrics_m(k_metric_adjust_position, adobe::metric_extractor_t::index_top)); position.x_m += fudge_left; position.y_m += fudge_top; /* NOTE (fbrereto) : All Eve containers need to expand themselves to compensate for the the case when their children have outsets. If this does not happen, you will see visual clipping of the children's visual outset artifacts. */ float left_shift(fudge_left - extents.horizontal().outset_m.first); float top_shift(fudge_top - extents.vertical().outset_m.first); ADOBE_REQUIRE_STATUS(::HIViewSetBoundsOrigin(control.control_m, left_shift, top_shift)); } /****************************************************************************************************/ template <typename Widget> adobe::extents_t apply_fudges(Widget& w, const adobe::extents_t& dimensions) { adobe::extents_t result(dimensions); set_metric_extractor(w); result.height() -= w.metrics_m(k_metric_adjust_size, adobe::metric_extractor_t::index_height); result.width() -= w.metrics_m(k_metric_adjust_size, adobe::metric_extractor_t::index_width); // frame inset and outsets are directly transcribed result.horizontal().outset_m.first += w.metrics_m(k_metric_outset, adobe::metric_extractor_t::index_left); result.horizontal().outset_m.second += w.metrics_m(k_metric_outset, adobe::metric_extractor_t::index_right); result.vertical().outset_m.first += w.metrics_m(k_metric_outset, adobe::metric_extractor_t::index_top); result.vertical().outset_m.second += w.metrics_m(k_metric_outset, adobe::metric_extractor_t::index_bottom); result.horizontal().frame_m.first += w.metrics_m(k_metric_frame, adobe::metric_extractor_t::index_left); result.horizontal().frame_m.second += w.metrics_m(k_metric_frame, adobe::metric_extractor_t::index_right); result.vertical().frame_m.first += w.metrics_m(k_metric_frame, adobe::metric_extractor_t::index_top); result.vertical().frame_m.second += w.metrics_m(k_metric_frame, adobe::metric_extractor_t::index_bottom); result.horizontal().inset_m.first += w.metrics_m(k_metric_inset, adobe::metric_extractor_t::index_left); result.horizontal().inset_m.second += w.metrics_m(k_metric_inset, adobe::metric_extractor_t::index_right); result.vertical().inset_m.first += w.metrics_m(k_metric_inset, adobe::metric_extractor_t::index_top); result.vertical().inset_m.second += w.metrics_m(k_metric_inset, adobe::metric_extractor_t::index_bottom); if (!result.vertical().poi_m.empty()) { // REVISIT (fbrereto) It will not always be safe to assume the first vertical poi is the baseline. result.vertical().poi_m[0] += w.metrics_m(adobe::implementation::k_metric_adjust_baseline); } return result; } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ adobe::extents_t measure(::ControlRef& control); /****************************************************************************************************/ template <typename Widget> adobe::extents_t measure(Widget& widget) { return apply_fudges(widget, measure(widget.control_m)); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename Widget> void set_bounds(Widget& widget, const point_2d_t& pos, const extents_t& ext) { assert(widget.control_m); point_2d_t position(pos); extents_t extents(ext); implementation::shed_fudges(widget, position, extents); ::Rect new_bounds = { static_cast<short>(position.y_m), static_cast<short>(position.x_m), static_cast<short>(position.y_m + extents.height()), static_cast<short>(position.x_m + extents.width()) }; set_bounds(widget.control_m, new_bounds); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ inline void set_name(::ControlRef& control, const std::string& name) { assert(control); ADOBE_REQUIRE_STATUS(::SetControlTitleWithCFString(control, localize_to_cfstring(name).get())); } /****************************************************************************************************/ /// See comment in adobe::implementation::get_name about the differences between names and field texts template <typename Widget> void set_name(Widget& widget, const std::string& name) { set_name(widget.control_m, name); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /// See comment in adobe::implementation::get_field_text about the differences between names and field texts template <typename T> void set_field_text(T&, const std::string& name); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename Widget> void set_theme(Widget& widget, adobe::theme_t theme) { assert(widget.control_m); widget.theme_m = theme; set_theme(widget.control_m, theme); } /****************************************************************************************************/ template <> void set_theme< ::ControlRef >(::ControlRef& control, adobe::theme_t theme); /****************************************************************************************************/ template <> void set_theme< ::TXNObject >(::TXNObject& hitextview, adobe::theme_t theme); /****************************************************************************************************/ template <typename Widget> void adorn_theme(Widget& widget, theme_t theme) { theme_t current(widget.theme_m); // wipe base from current if new base specified if (theme & theme_mask_s) current &= ~theme_mask_s; current |= theme; // logical OR the two themes together set_theme(widget, current); } /****************************************************************************************************/ template <typename Widget> void unadorn_theme(Widget& widget, theme_t theme) { theme_t current(widget.theme_m); current &= ~theme; // If no base is specified now, default to normal if (!(current & theme_mask_s)) current |= theme_normal_s; set_theme(widget, current); } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename T> void set_active(T&, bool make_active); /****************************************************************************************************/ template <> void set_active< ::ControlRef >(::ControlRef& control, bool make_active); /****************************************************************************************************/ template <typename T> void set_visible(T&, bool make_visible); /****************************************************************************************************/ template <> inline void set_visible< ::ControlRef >(::ControlRef& control, bool make_visible) { assert(control); ADOBE_REQUIRE_STATUS(::HIViewSetVisible(control, make_visible)); } /****************************************************************************************************/ template <typename T> void set_focused(T&, bool make_focused); /****************************************************************************************************/ template <> inline void set_focused< ::ControlRef >(::ControlRef& control, bool make_focused) { assert(control); set_focus(control, make_focused); } /****************************************************************************************************/ // REVISIT (fbrereto) is_focused needs to go away -- use a cached result of signal_focus instead template <typename T> bool is_focused(T&); /****************************************************************************************************/ template <> inline bool is_focused< ::ControlRef >(::ControlRef& control) { assert(control); ::ControlRef cur_focus; ADOBE_REQUIRE_STATUS(::GetKeyboardFocus(::GetControlOwner(control), &cur_focus)); return cur_focus == control; } /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ std::string convert_utf(::UniChar* buffer, std::size_t size); /****************************************************************************************************/ std::string convert_utf(UniChar* buffer); /****************************************************************************************************/ adobe::modifiers_t convert_modifiers(::UInt32 os_modifiers); /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ /****************************************************************************************************/ template <typename Target> ::EventTargetRef get_event_target(Target target); template <> inline ::EventTargetRef get_event_target< ::WindowRef >(::WindowRef target) { return ::GetWindowEventTarget(target); } template <> inline ::EventTargetRef get_event_target< ::ControlRef >(::ControlRef target) { return ::GetControlEventTarget(target); } #if 0 template <> inline ::EventTargetRef get_event_target< ::MenuRef >(::MenuRef target) { return ::GetMenuEventTarget(target); } #endif /****************************************************************************************************/ template <typename UserDataType> struct event_handler : boost::noncopyable { typedef UserDataType user_data_type; typedef typename adobe::auto_resource< ::EventHandlerRef > auto_ref_t; typedef typename adobe::auto_resource< ::EventHandlerUPP > auto_upp_t; typedef typename std::vector< ::EventTypeSpec > event_type_set_t; event_handler() : upp_m(::NewEventHandlerUPP(do_handle)), installed_m(false) { } virtual ~event_handler() { } void set_user_data(const user_data_type& data) { user_data_m = data; } template <typename Target> void install(Target& target) { if (is_installed()) return; if (event_type_set_m.empty()) throw std::runtime_error("No events specified for handler"); ::EventHandlerRef handler_ref(0); ::ADOBE_REQUIRE_STATUS(::InstallEventHandler( get_event_target(target), upp_m.get(), event_type_set_m.size(), &event_type_set_m[0], this, &handler_ref)); ref_m.reset(handler_ref); installed_m = true; } void uninstall() { if (!is_installed()) return; ref_m.reset(0); upp_m.reset(0); installed_m = false; } bool is_installed() const { return installed_m; } void insert_event(::UInt32 event_class, ::UInt32 event_kind) { ::EventTypeSpec event = { event_class, event_kind }; event_type_set_t::iterator pos(std::find(event_type_set_m.begin(), event_type_set_m.end(), event)); if (pos == event_type_set_m.end()) { event_type_set_m.push_back(event); if (is_installed()) ::ADOBE_REQUIRE_STATUS(::AddEventTypesToHandler( ref_m.get(), 1, &event)); } } void erase_event(::UInt32 event_class, ::UInt32 event_kind) { ::EventTypeSpec event = { event_class, event_kind }; event_type_set_t::iterator pos(adobe::find(event_type_set_m, event)); if (pos != event_type_set_m.end()) { event_type_set_m.erase(pos); if (is_installed()) ::ADOBE_REQUIRE_STATUS(::RemoveEventTypesFromHandler( ref_m.get(), 1, &event)); } } static pascal ::OSStatus do_handle( ::EventHandlerCallRef call_ref, ::EventRef event, void* data) try { event_handler<user_data_type>& myself(*reinterpret_cast<event_handler<user_data_type>*>(data)); return myself.handle_event(call_ref, event); } catch (const adobe::stream_error_t& err) { adobe::report_ui_element_error(adobe::format_stream_error(err)); return eventNotHandledErr; } catch (const std::exception& err) { adobe::report_ui_element_error(std::string("Exception: ") + err.what()); return eventNotHandledErr; } catch (...) { adobe::report_ui_element_error("Exception: Unknown"); return eventNotHandledErr; } virtual ::OSStatus handle_event( ::EventHandlerCallRef next, ::EventRef event) = 0; user_data_type user_data_m; private: auto_ref_t ref_m; auto_upp_t upp_m; event_type_set_t event_type_set_m; bool installed_m; }; /****************************************************************************************************/ } // namespace implementation /****************************************************************************************************/ } // namespace adobe /****************************************************************************************************/ #endif /****************************************************************************************************/ |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:21
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/begin Modified Files: Info.plist Jamfile.v2 version.plist Log Message: asl 1.0.13 Index: Info.plist =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/Info.plist,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Info.plist 21 Sep 2005 18:39:41 -0000 1.3 --- Info.plist 3 Feb 2006 18:33:38 -0000 1.4 *************** *** 3,55 **** <plist version="1.0"> <dict> ! <key>CFBundleDevelopmentRegion</key> ! <string>English</string> ! <key>CFBundleDocumentTypes</key> ! <array> ! <dict> ! <key>CFBundleTypeExtensions</key> ! <array> ! <string>adm</string> ! </array> ! <key>CFBundleTypeName</key> ! <string>Adam file</string> ! <key>CFBundleTypeRole</key> ! <string>Viewer</string> ! <key>LSTypeIsPackage</key> ! <false/> ! </dict> ! <dict> ! <key>CFBundleTypeExtensions</key> ! <array> ! <string>eve</string> ! </array> ! <key>CFBundleTypeName</key> ! <string>Eve file</string> ! <key>CFBundleTypeRole</key> ! <string>Viewer</string> ! <key>LSTypeIsPackage</key> ! <false/> ! </dict> ! </array> ! <key>CFBundleExecutable</key> ! <string>Adobe Begin</string> ! <key>CFBundleGetInfoString</key> ! <string>Adobe Begin version 1.0, Copyright © 2004-2005 by Adobe Systems, Inc. All rights reserved.</string> ! <key>CFBundleIconFile</key> ! <string>app_icon.icns</string> ! <key>CFBundleIdentifier</key> ! <string>com.adobe.begin</string> ! <key>CFBundleInfoDictionaryVersion</key> ! <string>6.0</string> ! <key>CFBundleName</key> ! <string>Adobe Begin.app</string> ! <key>CFBundlePackageType</key> ! <string>APPL</string> ! <key>CFBundleSignature</key> ! <string>????</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>CSResourcesFileMapped</key> ! <true/> </dict> </plist> --- 3,55 ---- <plist version="1.0"> <dict> ! <key>CFBundleDevelopmentRegion</key> ! <string>English</string> ! <key>CFBundleDocumentTypes</key> ! <array> ! <dict> ! <key>CFBundleTypeExtensions</key> ! <array> ! <string>adm</string> ! </array> ! <key>CFBundleTypeName</key> ! <string>Adam file</string> ! <key>CFBundleTypeRole</key> ! <string>Viewer</string> ! <key>LSTypeIsPackage</key> ! <false/> ! </dict> ! <dict> ! <key>CFBundleTypeExtensions</key> ! <array> ! <string>eve</string> ! </array> ! <key>CFBundleTypeName</key> ! <string>Eve file</string> ! <key>CFBundleTypeRole</key> ! <string>Viewer</string> ! <key>LSTypeIsPackage</key> ! <false/> ! </dict> ! </array> ! <key>CFBundleExecutable</key> ! <string>Adobe Begin</string> ! <key>CFBundleGetInfoString</key> ! <string>Adobe Begin version 1.0, Copyright © 2004-2005 by Adobe Systems, Inc. All rights reserved.</string> ! <key>CFBundleIconFile</key> ! <string>app_icon.icns</string> ! <key>CFBundleIdentifier</key> ! <string>com.adobe.begin</string> ! <key>CFBundleInfoDictionaryVersion</key> ! <string>6.0</string> ! <key>CFBundleName</key> ! <string>Adobe Begin.app</string> ! <key>CFBundlePackageType</key> ! <string>APPL</string> ! <key>CFBundleSignature</key> ! <string>????</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>CSResourcesFileMapped</key> ! <true/> </dict> </plist> Index: Jamfile.v2 =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/Jamfile.v2,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Jamfile.v2 24 Jan 2006 19:38:50 -0000 1.5 --- Jamfile.v2 3 Feb 2006 18:33:38 -0000 1.6 *************** *** 4,92 **** import os ; ! SOURCE_DIRECTORY = sources ; ! HEADER_DIRECTORY = headers ; switch [ os.name ] { case NT : # --- Windows --------------------------------------------------------------------------- ! { ! # ! # Directory name for Windows specific sources and headers ! # ! PLATFORM_DIRECTORIES_NAME = win32 ; ! # ! # Build settings for Windows ! # ! PLATFORM_SETTINGS = ! # ! # The header file containing the resource definitions is currently ! # used by win/ui_core_implementation.cpp to load an icon in begin. ! # ! <include>resources ! <include>. ! # ! # These definitions say that we're targetting Windows XP. ! # That means that we get various preprocessor definitions which we ! # need, such as the WS_EX_COMPOSITED window style. ! # ! <define>WINVER=0x501 <define>_WIN32_WINNT=0x501 <define>_WIN32_IE=0x501 ! <toolset>msvc:<linkflags>"gdi32.lib user32.lib comctl32.lib shell32.lib" ! # ! # If compiling with GCC we add -mno-cygwin to tell the cygwin compiler ! # and linker that we want a native Windows application. ! # ! <toolset>gcc:<cxxflags>"-mno-cygwin" ! <toolset>gcc:<linkflags>"-lgdi32 -lshell32 -luser32 -lcomctl32 -mno-cygwin" ! ; ! # ! # The resource file should only be included on the executable. ! # We don't want it in the library, so this PLATFORM_EXTRA ! # variable is defined. ! # ! PLATFORM_EXTRAS = resources/resources.rc ; ! } case FREEBSD : ! { ! PLATFORM_DIRECTORIES_NAME = fltk ; ! # ! # Details of *your* local FLTK2 installation must be added here. ! # ! PLATFORM_SETTINGS = <linkflags>"-L/usr/X11R6/lib -lXft -L/usr/local/lib -lfreetype -lz -lfontconfig -lXrender -lXext -lXi -lX11" ; ! PLATFORM_EXTRAS = ; ! } case MACOSX : # --- Mac OS (assumed) ------------------------------------------------------------------ ! { ! # ! # Directory name for MacOS specific sources ! # ! PLATFORM_DIRECTORIES_NAME = mac ; ! # ! # Build settings for MacOS ! # ! PLATFORM_SETTINGS = <toolset>darwin:<linkflags>"-framework Carbon" ; ! ! # ! # MacOS has no extra requirements. ! # ! PLATFORM_EXTRAS = ; ! } } # ------------------------------------------------------------------------------------------------- ! INCLUDE = <include>$(HEADER_DIRECTORY) <include>$(HEADER_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME) ; EXE_SOURCES = ! $(SOURCE_DIRECTORY)/express_viewer.cpp ! $(SOURCE_DIRECTORY)/report_exception.cpp ! $(SOURCE_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME)/main.cpp ! ; # ------------------------------------------------------------------------------------------------- --- 4,124 ---- import os ; ! SOURCE_DIRECTORY = sources ; ! HEADER_DIRECTORY = headers ; ! switch [ os.name ] { case NT : # --- Windows --------------------------------------------------------------------------- ! { ! # ! # Directory name for Windows specific sources and headers ! # ! PLATFORM_DIRECTORIES_NAME = ! win32 ! ; + # + # Build settings for Windows + # + PLATFORM_SETTINGS = + # + # The header file containing the resource definitions is currently + # used by win/ui_core_implementation.cpp to load an icon in begin. + # + <include>resources + <include>. + # + # These definitions say that we're targetting Windows XP. + # That means that we get various preprocessor definitions which we + # need, such as the WS_EX_COMPOSITED window style. + # + <define>WINVER=0x501 <define>_WIN32_WINNT=0x501 <define>_WIN32_IE=0x501 + <toolset>msvc:<linkflags>"gdi32.lib user32.lib comctl32.lib shell32.lib" ! # Commented out because manifests aren't working in boost 1.33.1 anyhow ! # ! # <toolset>msvc,<toolset-msvc:version>8.0:<define>ADOBE_VER=8 ! # <toolset>msvc,<toolset-msvc:version>7.1:<define>ADOBE_VER=7 ! # ! # If compiling with GCC we add -mno-cygwin to tell the cygwin compiler ! # and linker that we want a native Windows application. ! # ! <toolset>gcc:<cxxflags>"-mno-cygwin" ! <toolset>gcc:<linkflags>"-lgdi32 -lshell32 -luser32 -lcomctl32 -mno-cygwin" ! ; ! # ! # The resource file should only be included on the executable. ! # We don't want it in the library, so this PLATFORM_EXTRA ! # variable is defined. ! # ! PLATFORM_EXTRAS = ! resources/resources.rc ! ; ! } case FREEBSD : ! { ! PLATFORM_DIRECTORIES_NAME = ! fltk ! ; ! # ! # Details of *your* local FLTK2 installation must be added here. ! # ! PLATFORM_SETTINGS = ! <linkflags>"-L/usr/X11R6/lib -lXft -L/usr/local/lib -lfreetype -lz -lfontconfig -lXrender -lXext -lXi -lX11" ! ; ! PLATFORM_EXTRAS = ! ; ! } case MACOSX : # --- Mac OS (assumed) ------------------------------------------------------------------ ! { ! # ! # Directory name for MacOS specific sources ! # ! PLATFORM_DIRECTORIES_NAME = ! mac ! ; ! # ! # Build settings for MacOS ! # ! PLATFORM_SETTINGS = ! <toolset>darwin:<linkflags>"-framework Carbon" ! ; ! ! # ! # MacOS has no extra requirements. ! # ! PLATFORM_EXTRAS = ! ; ! } } # ------------------------------------------------------------------------------------------------- ! INCLUDE = ! <include>$(HEADER_DIRECTORY) ! <include>$(HEADER_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME) ! ; EXE_SOURCES = ! $(SOURCE_DIRECTORY)/express_viewer.cpp ! $(SOURCE_DIRECTORY)/report_exception.cpp ! $(SOURCE_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME)/main.cpp ! ; ! ! # ------------------------------------------------------------------------------------------------- ! ! project adobe/begin ! : requirements ! <user-interface>gui ! $(INCLUDE) ! : usage-requirements ! $(INCLUDE) ! ; # ------------------------------------------------------------------------------------------------- *************** *** 94,122 **** switch [ os.name ] { ! case MACOSX : ! { ! BINARY_NAME = "Adobe Begin" ; ! } case * : ! { ! BINARY_NAME = "begin" ; ! } } - # ------------------------------------------------------------------------------------------------- ! project adobe/begin ! : requirements ! <user-interface>gui ! $(INCLUDE) ! : usage-requirements ! $(INCLUDE) ! ; exe $(BINARY_NAME) ! : $(EXE_SOURCES) ! /adobe/adobe_widgets//adobe_widgets ! $(PLATFORM_EXTRAS) ! : $(PLATFORM_SETTINGS) ! ; # Construct the destination path location --- 126,152 ---- switch [ os.name ] { ! case MACOSX : ! { ! BINARY_NAME = "Adobe Begin" ; ! } ! case NT : ! { ! manifest begin.exe : resources/begin.exe.manifesttmpl ; ! BINARY_NAME = "begin" ; ! } case * : ! { ! BINARY_NAME "begin" ; ! } } ! # ------------------------------------------------------------------------------------------------- exe $(BINARY_NAME) ! : $(EXE_SOURCES) ! /adobe/adobe_widgets//adobe_widgets ! $(PLATFORM_EXTRAS) ! : $(PLATFORM_SETTINGS) ! ; # Construct the destination path location *************** *** 126,176 **** switch [ os.name ] { ! case MACOSX : ! { ! # set up the bundle of the app ! ! install "Adobe Begin.app/Contents" ! : Info.plist ! resources/PkgInfo ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents" ! ; ! ! install "Adobe Begin.app/Contents/MacOS" ! : "Adobe Begin" ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/MacOS" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/MacOS" ! ; ! ! install "Adobe Begin.app/Contents/Resources/begin.nib" ! : [ glob resources/begin.nib/*.* ] ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/Resources/begin.nib" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/Resources/begin.nib" ! ; ! ! install "Adobe Begin.app/Contents/Resources" ! : resources/app_icon.icns ! resources/editor.adm ! resources/editor.eve ! resources/eve_globals.scp ! resources/glossary.xstr ! resources/link_icon.png ! resources/metrics_glossary.xstr ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/Resources" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/Resources" ! ; ! } ! case * : ! { ! install "Adobe Begin" ! : begin ! resources/editor.adm ! resources/editor.eve ! resources/eve_globals.scp ! resources/glossary.xstr ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin" ! ; ! } } --- 156,219 ---- switch [ os.name ] { ! case MACOSX : ! { ! # set up the bundle of the app ! ! install "Adobe Begin.app/Contents" ! : Info.plist ! resources/PkgInfo ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents" ! ; ! ! install "Adobe Begin.app/Contents/MacOS" ! : "Adobe Begin" ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/MacOS" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/MacOS" ! ; ! ! install "Adobe Begin.app/Contents/Resources/begin.nib" ! : [ glob resources/begin.nib/*.* ] ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/Resources/begin.nib" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/Resources/begin.nib" ! ; ! ! install "Adobe Begin.app/Contents/Resources" ! : resources/app_icon.icns ! resources/editor.adm ! resources/editor.eve ! resources/eve_globals.scp ! resources/glossary.xstr ! resources/link_icon.png ! resources/metrics_glossary.xstr ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin.app/Contents/Resources" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin.app/Contents/Resources" ! ; ! } ! case NT : ! { ! install "Adobe Begin" ! : begin ! begin.exe ! resources/editor.adm ! resources/editor.eve ! resources/eve_globals.scp ! resources/glossary.xstr ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin" ! ; ! } ! case * : ! { ! install "Adobe Begin" ! : begin ! resources/editor.adm ! resources/editor.eve ! resources/eve_globals.scp ! resources/glossary.xstr ! : <variant>release:<location>$(DEST_PATH)"release/Adobe Begin" ! <variant>debug:<location>$(DEST_PATH)"debug/Adobe Begin" ! ; ! } } Index: version.plist =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/begin/version.plist,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** version.plist 7 Jul 2005 22:16:18 -0000 1.1 --- version.plist 3 Feb 2006 18:33:38 -0000 1.2 *************** *** 3,16 **** <plist version="1.0"> <dict> ! <key>BuildVersion</key> ! <string>92</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>ProductBuildVersion</key> ! <string>7K571</string> ! <key>ProjectName</key> ! <string>NibPBTemplates</string> ! <key>SourceVersion</key> ! <string>1200000</string> </dict> </plist> --- 3,16 ---- <plist version="1.0"> <dict> ! <key>BuildVersion</key> ! <string>92</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>ProductBuildVersion</key> ! <string>7K571</string> ! <key>ProjectName</key> ! <string>NibPBTemplates</string> ! <key>SourceVersion</key> ! <string>1200000</string> </dict> </plist> |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:21
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/resources In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets/resources Modified Files: resources.h Log Message: asl 1.0.13 Index: resources.h =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/resources/resources.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** resources.h 7 Jul 2005 22:16:14 -0000 1.1 --- resources.h 3 Feb 2006 18:33:37 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ // --- 1,6 ---- /* ! Copyright 2005 Ralph Thomas ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ // *************** *** 13,17 **** /// The main application icon. // ! #define RES_APP_ICON 2 /****************************************************************************************************/ --- 13,17 ---- /// The main application icon. // ! #define RES_APP_ICON 2 /****************************************************************************************************/ |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:21
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/widget_lib In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources/widget_lib Modified Files: widget_reference.dox Log Message: asl 1.0.13 Index: widget_reference.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/widget_lib/widget_reference.dox,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** widget_reference.dox 28 Apr 2005 23:23:05 -0000 1.2 --- widget_reference.dox 3 Feb 2006 18:33:36 -0000 1.3 *************** *** 13,49 **** \section wr_toc Table of Contents ! -# \ref wr_overview ! -# \ref wr_views_reference ! -# \ref wr_view_common_attributes ! -# \ref wr_view_classes ! -# bevel_button ! -# \ref wr_bevel_button "button_beveled" ! -# \ref wr_bevel_button "checkbox_beveled" ! -# \ref wr_bevel_button "radio_button_beveled" [...1653 lines suppressed...] ! <tr> ! <td><code>items[]</code></td> ! <td><code>dictionary</code></td> ! <td><i>required</i></td> ! <td>tab specification</td> ! </tr> ! <tr> ! <td><code>items[].name</code></td> ! <td><code>string</code></td> ! <td><i>required</i></td> ! <td>name of the tab</td> ! </tr> ! <tr> ! <td><code>items[].value</code></td> ! <td><i>any</i></td> ! <td><i>n/a</i></td> ! <td>value of the tab</td> ! </tr> </table> */ |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:21
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources/asl/concepts Modified Files: concept_assignable.dox concept_convertible_to_bool.dox concept_convertible_to_function.dox concept_convertible_to_range.dox concept_defaultconstructible.dox concept_equalitycomparable.dox concept_lessthancomparable.dox concept_regular_type.dox concept_transform_function.dox Log Message: asl 1.0.13 Index: concept_transform_function.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_transform_function.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_transform_function.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_transform_function.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 28,32 **** \refinement_of ! - UnaryFunction \associated_types --- 28,32 ---- \refinement_of ! - UnaryFunction \associated_types *************** *** 34,57 **** \notation <table> ! <tr> ! <td valign="top"><code>F</code></td> ! <td valign="top">A type that is a model of TransformFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">Argument type of F</td> ! </tr> ! <tr> ! <td valign="top"><code>Result</code></td> ! <td valign="top">Result type of F</td> ! </tr> ! <tr> ! <td valign="top"><code>f</code></td> ! <td valign="top">Object of type <code>F</code></td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> --- 34,57 ---- \notation <table> ! <tr> ! <td valign="top"><code>F</code></td> ! <td valign="top">A type that is a model of TransformFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">Argument type of F</td> ! </tr> ! <tr> ! <td valign="top"><code>Result</code></td> ! <td valign="top">Result type of F</td> ! </tr> ! <tr> ! <td valign="top"><code>f</code></td> ! <td valign="top">Object of type <code>F</code></td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> *************** *** 65,69 **** \invariants ! - The expression <code>f(x)</code> is <i>not</i> permitted to change <code>f</code>'s state. \models --- 65,69 ---- \invariants ! - The expression <code>f(x)</code> is <i>not</i> permitted to change <code>f</code>'s state. \models Index: concept_equalitycomparable.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_equalitycomparable.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_equalitycomparable.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_equalitycomparable.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 33,44 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of EqualityComparable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code>, <code>z</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> --- 33,44 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of EqualityComparable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code>, <code>z</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> *************** *** 47,86 **** \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Equality</td> ! <td valign="top"><code>x == y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Inequality</td> ! <td valign="top"><code>x != y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Equality</td> ! <td valign="top"><code>x == y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code>==</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Inequality</td> ! <td valign="top"><code>x != y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code>==</code></td> ! <td valign="top">Equivalent to <code>!(x == y)</code></td> ! <td valign="top"> </td> ! </tr> </table> --- 47,86 ---- \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Equality</td> ! <td valign="top"><code>x == y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Inequality</td> ! <td valign="top"><code>x != y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Equality</td> ! <td valign="top"><code>x == y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code>==</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Inequality</td> ! <td valign="top"><code>x != y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code>==</code></td> ! <td valign="top">Equivalent to <code>!(x == y)</code></td> ! <td valign="top"> </td> ! </tr> </table> *************** *** 89,117 **** \invariants <table border> ! <tr> ! <td valign="top">Identity</td> ! <td valign="top"><code>&x == &y</code> implies <code>x</code> == <code>y</code></td> ! </tr> ! <tr> ! <td valign="top">Reflexivity</td> ! <td valign="top"><code>x == x</code></td> ! </tr> ! <tr> ! <td valign="top">Symmetry</td> ! <td valign="top"><code>x == y</code> implies <code>y == x</code></td> ! </tr> ! <tr> ! <td valign="top">Transitivity</td> ! <td valign="top"><code>x == y</code> and <code>y == z</code> implies <code>x == z</code></td> ! </tr> </table> \models ! - int ! - <code>std::vector<T></code> \notes \see_also ! - \ref stldoc_LessThanComparable */ --- 89,117 ---- \invariants <table border> ! <tr> ! <td valign="top">Identity</td> ! <td valign="top"><code>&x == &y</code> implies <code>x</code> == <code>y</code></td> ! </tr> ! <tr> ! <td valign="top">Reflexivity</td> ! <td valign="top"><code>x == x</code></td> ! </tr> ! <tr> ! <td valign="top">Symmetry</td> ! <td valign="top"><code>x == y</code> implies <code>y == x</code></td> ! </tr> ! <tr> ! <td valign="top">Transitivity</td> ! <td valign="top"><code>x == y</code> and <code>y == z</code> implies <code>x == z</code></td> ! </tr> </table> \models ! - int ! - <code>std::vector<T></code> \notes \see_also ! - \ref stldoc_LessThanComparable */ Index: concept_lessthancomparable.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_lessthancomparable.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_lessthancomparable.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_lessthancomparable.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 35,46 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of LessThanComparable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code>, <code>z</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> --- 35,46 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of LessThanComparable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code>, <code>z</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> *************** *** 57,122 **** \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Less</td> ! <td valign="top"><code>x < y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Greater</td> ! <td valign="top"><code>x > y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Less or equal</td> ! <td valign="top"><code>x <= y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Greater or equal</td> ! <td valign="top"><code>x >= y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Less</td> ! <td valign="top"><code>x < y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Greater</td> ! <td valign="top"><code>x > y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>y < x</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Less or equal</td> ! <td valign="top"><code>x <= y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>!(y < x)</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Greater or equal</td> ! <td valign="top"><code>x >= y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>!(x < y)</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> </table> --- 57,122 ---- \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Less</td> ! <td valign="top"><code>x < y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Greater</td> ! <td valign="top"><code>x > y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Less or equal</td> ! <td valign="top"><code>x <= y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> ! <tr> ! <td valign="top">Greater or equal</td> ! <td valign="top"><code>x >= y</code></td> ! <td valign="top"> </td> ! <td valign="top">Convertible to <code>bool</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Less</td> ! <td valign="top"><code>x < y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Greater</td> ! <td valign="top"><code>x > y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>y < x</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Less or equal</td> ! <td valign="top"><code>x <= y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>!(y < x)</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Greater or equal</td> ! <td valign="top"><code>x >= y</code></td> ! <td valign="top"><code>x</code> and <code>y</code> are in the domain of <code><</code></td> ! <td valign="top">Equivalent to <code>!(x < y)</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! </tr> </table> *************** *** 125,145 **** \invariants <table border> ! <tr> ! <td valign="top">Irreflexivity</td> ! <td valign="top"><code>x < x</code> must be false.</td> ! </tr> ! <tr> ! <td valign="top">Antisymmetry</td> ! <td valign="top"><code>x < y</code> implies !(y < x) <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Transitivity</td> ! <td valign="top"><code>x < y</code> and <code>y < z</code> implies <code>x < z</code> <A href="#3">[3]</A></td> ! </tr> </table> \models ! - int ! - adobe::name_t \notes --- 125,145 ---- \invariants <table border> ! <tr> ! <td valign="top">Irreflexivity</td> ! <td valign="top"><code>x < x</code> must be false.</td> ! </tr> ! <tr> ! <td valign="top">Antisymmetry</td> ! <td valign="top"><code>x < y</code> implies !(y < x) <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Transitivity</td> ! <td valign="top"><code>x < y</code> and <code>y < z</code> implies <code>x < z</code> <A href="#3">[3]</A></td> ! </tr> </table> \models ! - int ! - adobe::name_t \notes *************** *** 154,157 **** \see_also ! - \ref stldoc_EqualityComparable */ --- 154,157 ---- \see_also ! - \ref stldoc_EqualityComparable */ Index: concept_assignable.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_assignable.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_assignable.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_assignable.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 33,44 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of Assignable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> --- 33,44 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of Assignable</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code>, <code>y</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> </table> *************** *** 47,125 **** \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>X</code></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"> <pre>X x(y); X x = y; </pre> ! </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Assignment</td> ! <td valign="top"><code>x = y</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"><code>X&</code></td> ! </tr> ! <tr> ! <td valign="top">Swap</td> ! <td valign="top"><code>adobe::swap(x,y)</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>void</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>X(x)</code> is a copy of <code>x</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>X(x)</code> is a copy of <code>x</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"> <pre>X x(y); X x = y; </pre> ! </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>x</code> is a copy of <code>y</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Assignment</td> ! <td valign="top"><code>x</code> = <code>y</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>x</code> is a copy of <code>y</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Swap</td> ! <td valign="top"><code>adobe::swap(x,y)</code><A href="#3">[3]</A></td> ! <td valign="top"> </td> ! <td valign="top"> Equivalent to <pre>{ X tmp = x; --- 47,125 ---- \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>X</code></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"> <pre>X x(y); X x = y; </pre> ! </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Assignment</td> ! <td valign="top"><code>x = y</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"><code>X&</code></td> ! </tr> ! <tr> ! <td valign="top">Swap</td> ! <td valign="top"><code>adobe::swap(x,y)</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>void</code></td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>X(x)</code> is a copy of <code>x</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"><code>X(x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>X(x)</code> is a copy of <code>x</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Copy constructor</td> ! <td valign="top"> <pre>X x(y); X x = y; </pre> ! </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>x</code> is a copy of <code>y</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Assignment</td> ! <td valign="top"><code>x</code> = <code>y</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"><code>x</code> is a copy of <code>y</code> <A href="#2">[2]</A></td> ! </tr> ! <tr> ! <td valign="top">Swap</td> ! <td valign="top"><code>adobe::swap(x,y)</code><A href="#3">[3]</A></td> ! <td valign="top"> </td> ! <td valign="top"> Equivalent to <pre>{ X tmp = x; *************** *** 128,134 **** } </pre> ! </td> ! <td valign="top"> </td> ! </tr> </table> --- 128,134 ---- } </pre> ! </td> ! <td valign="top"> </td> ! </tr> </table> *************** *** 138,142 **** \models ! - int \notes --- 138,142 ---- \models ! - int \notes *************** *** 154,159 **** \see_also ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_EqualityComparable */ --- 154,159 ---- \see_also ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_EqualityComparable */ Index: concept_regular_type.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_regular_type.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_regular_type.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_regular_type.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. the intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. the intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 28,34 **** \refinement_of ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_Assignable ! - \ref stldoc_EqualityComparable \notation --- 28,34 ---- \refinement_of ! - \ref stldoc_DefaultConstructible ! - \ref stldoc_Assignable ! - \ref stldoc_EqualityComparable \notation *************** *** 41,51 **** \models ! - adobe::name_t ! - adobe::copy_on_write \notes \see_also ! - Alex Stepanov's paper on the <a href="http://www.stepanovpapers.com/DeSt98.pdf">concept of regular types</a>. */ --- 41,51 ---- \models ! - adobe::name_t ! - adobe::copy_on_write \notes \see_also ! - Alex Stepanov's paper on the <a href="http://www.stepanovpapers.com/DeSt98.pdf">concept of regular types</a>. */ Index: concept_convertible_to_function.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_convertible_to_function.dox,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** concept_convertible_to_function.dox 2 Dec 2005 02:59:15 -0000 1.2 --- concept_convertible_to_function.dox 3 Feb 2006 18:33:35 -0000 1.3 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 26,34 **** \description A ConvertibleToFunction is simply something which can be invoked using function notation - or something that \c boost::bind can convert to a function. Specifically, a ConvertibleToFunction can be: ! - A pointer to a function ! - A pointer to a class or struct data member (argument is a pointer or a reference to a struct/class instance) ! - A pointer to a class or struct member function (first argument is a pointer or a reference to a struct/class instance; Member function arguments follow in order) ! - A \c boost::reference_wrapper to a ConvertibleToFunction ! - A function object Where functions are passed as template parameters in the Adobe Source Libraries, any ConvertibleToFunction may be used. The idea is that <code>boost::bind(x, ...);</code> is a valid expression where <code>...</code> are arguments to <code>x</code>. <code>x</code>, in this case, is ConvertibleToFunction. --- 26,34 ---- \description A ConvertibleToFunction is simply something which can be invoked using function notation - or something that \c boost::bind can convert to a function. Specifically, a ConvertibleToFunction can be: ! - A pointer to a function ! - A pointer to a class or struct data member (argument is a pointer or a reference to a struct/class instance) ! - A pointer to a class or struct member function (first argument is a pointer or a reference to a struct/class instance; Member function arguments follow in order) ! - A \c boost::reference_wrapper to a ConvertibleToFunction ! - A function object Where functions are passed as template parameters in the Adobe Source Libraries, any ConvertibleToFunction may be used. The idea is that <code>boost::bind(x, ...);</code> is a valid expression where <code>...</code> are arguments to <code>x</code>. <code>x</code>, in this case, is ConvertibleToFunction. *************** *** 40,55 **** \notation <table> ! <tr> ! <td valign="top"><code>F</code></td> ! <td valign="top">A type that is a model of ConvertibleToFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>x1...xn</code></td> ! <td valign="top">An optional argument list for the type that is a model of ConvertibleToFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>f</code></td> ! <td valign="top">Object of type <code>F</code></td> ! </tr> </table> --- 40,55 ---- \notation <table> ! <tr> ! <td valign="top"><code>F</code></td> ! <td valign="top">A type that is a model of ConvertibleToFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>x1...xn</code></td> ! <td valign="top">An optional argument list for the type that is a model of ConvertibleToFunction</td> ! </tr> ! <tr> ! <td valign="top"><code>f</code></td> ! <td valign="top">Object of type <code>F</code></td> ! </tr> </table> *************** *** 58,70 **** \valid_expressions <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Convertible</td> ! <td valign="top"><code>boost::bind(&f, x1...xn);</code></td> ! <td valign="top"> </td> ! <td valign="top">An invokable <code>boost::function</code> whose template argument is the function signature of <code>f</code></td> ! </tr> </table> --- 58,70 ---- \valid_expressions <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Convertible</td> ! <td valign="top"><code>boost::bind(&f, x1...xn);</code></td> ! <td valign="top"> </td> ! <td valign="top">An invokable <code>boost::function</code> whose template argument is the function signature of <code>f</code></td> ! </tr> </table> *************** *** 76,80 **** \models ! - Anything that is acceptable to <code>boost::bind</code>. \example --- 76,80 ---- \models ! - Anything that is acceptable to <code>boost::bind</code>. \example Index: concept_convertible_to_range.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_convertible_to_range.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_convertible_to_range.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_convertible_to_range.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2002 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2002 - 2004 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 24,30 **** \description ConvertibleToRange denotes a sequence of the form: <code>[begin, end)</code>. The elements of the range are the beginning element to the element before the end element. The following are examples of ranges: ! - A <i>container</i>, denotes a range <code>[container.begin(), container.end())</code> ! - An <i>array</i>, denotes a range <code>[array[0], array[sizeof(array)/sizeof(array[0])])</code> ! - An <i>std::pair</i> of <i>iterators</i> denotes a range <code>[pair.first, pair.last)</code> \refinement_of --- 24,30 ---- \description ConvertibleToRange denotes a sequence of the form: <code>[begin, end)</code>. The elements of the range are the beginning element to the element before the end element. The following are examples of ranges: ! - A <i>container</i>, denotes a range <code>[container.begin(), container.end())</code> ! - An <i>array</i>, denotes a range <code>[array[0], array[sizeof(array)/sizeof(array[0])])</code> ! - An <i>std::pair</i> of <i>iterators</i> denotes a range <code>[pair.first, pair.last)</code> \refinement_of *************** *** 34,53 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of ConvertibleToRange</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>I</code></td> ! <td valign="top">A type for iterating over objects of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>p</code>, <code>q</code></td> ! <td valign="top">Objects of type <code>I</code></td> ! </tr> </table> --- 34,53 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of ConvertibleToRange</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>I</code></td> ! <td valign="top">A type for iterating over objects of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>p</code>, <code>q</code></td> ! <td valign="top">Objects of type <code>I</code></td> ! </tr> </table> Index: concept_convertible_to_bool.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_convertible_to_bool.dox,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** concept_convertible_to_bool.dox 2 Dec 2005 02:59:15 -0000 1.2 --- concept_convertible_to_bool.dox 3 Feb 2006 18:33:35 -0000 1.3 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 33,48 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of ConvertibleToBool</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>b</code></td> ! <td valign="top">Object of type <code>bool</code></td> ! </tr> </table> --- 33,48 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of ConvertibleToBool</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">Object of type <code>X</code></td> ! </tr> ! <tr> ! <td valign="top"><code>b</code></td> ! <td valign="top">Object of type <code>bool</code></td> ! </tr> </table> *************** *** 51,90 **** \valid_expressions <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>bool b = x;</code></td> ! <td valign="top"> </td> ! <td valign="top">bool</td> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>if (x)</code><br>-or-<br><code>if (!x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> \expression_semantics <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>bool b = x;</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>if (x)</code><br>-or-<br><code>if (!x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> --- 51,90 ---- \valid_expressions <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>bool b = x;</code></td> ! <td valign="top"> </td> ! <td valign="top">bool</td> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>if (x)</code><br>-or-<br><code>if (!x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> \expression_semantics <table> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>bool b = x;</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">ConvertibleToBool</td> ! <td valign="top"><code>if (x)</code><br>-or-<br><code>if (!x)</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> *************** *** 94,99 **** \models ! - a pointer ! - adobe::name_t \notes --- 94,99 ---- \models ! - a pointer ! - adobe::name_t \notes Index: concept_defaultconstructible.dox =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/asl/concepts/concept_defaultconstructible.dox,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** concept_defaultconstructible.dox 19 Mar 2005 00:16:41 -0000 1.1 --- concept_defaultconstructible.dox 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 3,19 **** /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ --- 3,19 ---- /* ! ADOBE CONFIDENTIAL ! ___________________ ! Copyright 2003 - 2003 Adobe Systems Incorporated ! All Rights Reserved. ! NOTICE: All information contained herein is, and remains the property of ! Adobe Systems Incorporated and its suppliers, if any. The intellectual and ! technical concepts contained herein are proprietary to Adobe Systems Incorporated ! and its suppliers and may be covered by U.S. and Foreign Patents, patents ! in process, and are protected by trade secret or copyright law. Dissemination ! of this information or reproduction of this material is strictly forbidden ! unless prior written permission is obtained from Adobe Systems Incorporated. */ *************** *** 33,44 **** \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of DefaultConstructible</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">An object of type <code>X</code></td> ! </tr> </table> --- 33,44 ---- \notation <table> ! <tr> ! <td valign="top"><code>X</code></td> ! <td valign="top">A type that is a model of DefaultConstructible</td> ! </tr> ! <tr> ! <td valign="top"><code>x</code></td> ! <td valign="top">An object of type <code>X</code></td> ! </tr> </table> *************** *** 47,86 **** \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X()</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>X</code></td> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X x;</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X()</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X x;</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> --- 47,86 ---- \valid_expressions <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Type requirements</th><th>Return type</th> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X()</code></td> ! <td valign="top"> </td> ! <td valign="top"><code>X</code></td> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X x;</code> <A href="#1">[1]</A></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> \expression_semantics <table border> ! <tr> ! <th>Name</th><th>Expression</th><th>Precondition</th><th>Semantics</th><th>Postcondition</th> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X()</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> ! <tr> ! <td valign="top">Default constructor</td> ! <td valign="top"><code>X x;</code></td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! <td valign="top"> </td> ! </tr> </table> *************** *** 88,94 **** \models ! - int ! - adobe::name_t ! - adobe::copy_on_write \notes --- 88,94 ---- \models ! - int ! - adobe::name_t ! - adobe::copy_on_write \notes *************** *** 97,100 **** \see_also ! - \ref stldoc_Assignable */ --- 97,100 ---- \see_also ! - \ref stldoc_Assignable */ |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:18
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/future/widgets Modified Files: Jamfile.v2 Log Message: asl 1.0.13 Index: Jamfile.v2 =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/future/widgets/Jamfile.v2,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** Jamfile.v2 24 Jan 2006 19:38:46 -0000 1.7 --- Jamfile.v2 3 Feb 2006 18:33:36 -0000 1.8 *************** *** 12,17 **** COMMON_SOURCES = client_assembler - ui_core ui_core_common ; --- 12,17 ---- COMMON_SOURCES = client_assembler ui_core_common + ui_core ; *************** *** 22,25 **** --- 22,26 ---- display ui_overlay + ui_core_implementation ; *************** *** 83,87 **** # Additional sources that only exist for MacOS # ! PLATFORM_SOURCES = metrics ; # --- 84,90 ---- # Additional sources that only exist for MacOS # ! PLATFORM_SOURCES = ! metrics ! ; # *************** *** 127,135 **** lib adobe_widgets : ! [ obj ui_core_implementation ! : $(SOURCE_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME)/ui_core_implementation.cpp ! : $(PLATFORM_SETTINGS) ! $(INCLUDE) ! <toolset>darwin:<cxxflags>"-Wno-deprecated-declarations" ] $(SOURCE_DIRECTORY)/$(COMMON_SOURCES).cpp --- 130,138 ---- lib adobe_widgets : ! [ obj os_utilities ! : $(SOURCE_DIRECTORY)/$(PLATFORM_DIRECTORIES_NAME)/os_utilities.cpp ! : $(PLATFORM_SETTINGS) ! $(INCLUDE) ! <toolset>darwin:<cxxflags>"-Wno-deprecated-declarations" ] $(SOURCE_DIRECTORY)/$(COMMON_SOURCES).cpp |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:14
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/config/compiler In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/config/compiler Modified Files: gcc.hpp visualc.hpp Log Message: asl 1.0.13 Index: gcc.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/config/compiler/gcc.hpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gcc.hpp 6 Jan 2006 18:02:37 -0000 1.2 --- gcc.hpp 3 Feb 2006 18:33:35 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 13,17 **** #ifndef ADOBE_CONFIG_HPP ! #error "This file is intended to be included by <adobe/config.hpp> -- please use that file directly." #endif --- 13,17 ---- #ifndef ADOBE_CONFIG_HPP ! #error "This file is intended to be included by <adobe/config.hpp> -- please use that file directly." #endif Index: visualc.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/config/compiler/visualc.hpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** visualc.hpp 6 Jan 2006 18:02:37 -0000 1.2 --- visualc.hpp 3 Feb 2006 18:33:35 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 13,17 **** #ifndef ADOBE_CONFIG_HPP ! #error "This file is intended to be included by <adobe/config.hpp> -- please use that file directly." #endif --- 13,17 ---- #ifndef ADOBE_CONFIG_HPP ! #error "This file is intended to be included by <adobe/config.hpp> -- please use that file directly." #endif *************** *** 19,41 **** #ifndef ADOBE_TEST_MICROSOFT_NO_DEPRECATE ! #define ADOBE_TEST_MICROSOFT_NO_DEPRECATE 1 #endif #if ADOBE_TEST_MICROSOFT_NO_DEPRECATE ! #if _MSC_VER == 1400 ! /* ! The explanation for this check is explained at ! http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues ! */ ! #ifndef _CRT_SECURE_NO_DEPRECATE ! #error "Microsoft 'Safe Standard C Library' is not supported. See <http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues>" ! #endif ! #ifndef _SCL_SECURE_NO_DEPRECATE ! #error "Microsoft 'Safe Standard C++ Library' is not supported. See <http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues>" ! #endif ! #endif #endif --- 19,41 ---- #ifndef ADOBE_TEST_MICROSOFT_NO_DEPRECATE ! #define ADOBE_TEST_MICROSOFT_NO_DEPRECATE 1 #endif #if ADOBE_TEST_MICROSOFT_NO_DEPRECATE ! #if _MSC_VER == 1400 ! /* ! The explanation for this check is explained at ! http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues ! */ ! #ifndef _CRT_SECURE_NO_DEPRECATE ! #error "Microsoft 'Safe Standard C Library' is not supported. See <http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues>" ! #endif ! #ifndef _SCL_SECURE_NO_DEPRECATE ! #error "Microsoft 'Safe Standard C++ Library' is not supported. See <http://opensource.adobe.com/twiki/bin/view/AdobeSource/MicrosoftVisualCPP8Issues>" ! #endif ! #endif #endif |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:14
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/documentation/sources Modified Files: documentation.doxygen Log Message: asl 1.0.13 Index: documentation.doxygen =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/documentation/sources/documentation.doxygen,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** documentation.doxygen 24 Jan 2006 19:38:43 -0000 1.20 --- documentation.doxygen 3 Feb 2006 18:33:35 -0000 1.21 *************** *** 209,212 **** --- 209,213 ---- "requirements=\par Requirements:" \ "see_also=\par See Also:" \ + "see_only=\par See:" \ "tutorial=\par Tutorial:" \ "type_requirements=\par Type Requirements:" \ *************** *** 494,497 **** --- 495,499 ---- ./asl/algorithm.dox \ ./asl/conversion.dox \ + ./asl/cmath.dox \ ../../future/enum_ops.hpp \ ./asl/eve.dox \ *************** *** 515,519 **** ./widget_lib/widget_reference.dox \ ../../algorithm.hpp \ ! ../../algorithm/reverse.hpp \ ../../array.hpp \ ../../array_fwd.hpp \ --- 517,521 ---- ./widget_lib/widget_reference.dox \ ../../algorithm.hpp \ ! ../../algorithm/reverse.hpp \ ../../array.hpp \ ../../array_fwd.hpp \ *************** *** 525,528 **** --- 527,531 ---- ../../counter.hpp \ ../../conversion.hpp \ + ../../cmath.hpp \ ../../dancing_links.hpp \ ../../dictionary.hpp \ |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:14
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/algorithm In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/algorithm Modified Files: assign.hpp reverse.hpp Log Message: asl 1.0.13 Index: reverse.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/algorithm/reverse.hpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** reverse.hpp 6 Jan 2006 18:02:35 -0000 1.1 --- reverse.hpp 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /*************************************************************************************************/ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ /*************************************************************************************************/ *************** *** 36,54 **** I reverse_append(I first, I last, I result) { ! while (first != last) ! { ! I prior(first); ! ++first; ! adobe::unsafe::set_next(prior, result); // Intentional ADL ! result = prior; ! } ! return result; } template <typename R, // R models NodeRange ! typename I> // I models NodeIterator inline I reverse_append(R& range, I result) { ! return adobe::unsafe::reverse_append(boost::begin(range), boost::end(range), result); } --- 36,54 ---- I reverse_append(I first, I last, I result) { ! while (first != last) ! { ! I prior(first); ! ++first; ! adobe::unsafe::set_next(prior, result); // Intentional ADL ! result = prior; ! } ! return result; } template <typename R, // R models NodeRange ! typename I> // I models NodeIterator inline I reverse_append(R& range, I result) { ! return adobe::unsafe::reverse_append(boost::begin(range), boost::end(range), result); } *************** *** 56,60 **** inline I reverse_nodes(I first, I last) { ! return adobe::unsafe::reverse_append(first, last, last); } --- 56,60 ---- inline I reverse_nodes(I first, I last) { ! return adobe::unsafe::reverse_append(first, last, last); } *************** *** 62,66 **** inline typename boost::range_iterator<R>::type reverse_nodes(R& range) { ! return adobe::unsafe::reverse_nodes(boost::begin(range), boost::end(range)); } --- 62,66 ---- inline typename boost::range_iterator<R>::type reverse_nodes(R& range) { ! return adobe::unsafe::reverse_nodes(boost::begin(range), boost::end(range)); } *************** *** 84,88 **** inline void reverse(BidirectionalRange& range) { ! std::reverse(boost::begin(range), boost::end(range)); } --- 84,88 ---- inline void reverse(BidirectionalRange& range) { ! std::reverse(boost::begin(range), boost::end(range)); } *************** *** 90,94 **** inline void reverse_copy(BidirectionalRange& range, OutputIterator result) { ! std::reverse_copy(boost::begin(range), boost::end(range), result); } --- 90,94 ---- inline void reverse_copy(BidirectionalRange& range, OutputIterator result) { ! std::reverse_copy(boost::begin(range), boost::end(range), result); } *************** *** 96,100 **** inline void reverse_copy(const BidirectionalRange& range, OutputIterator result) { ! std::reverse_copy(boost::begin(range), boost::end(range), result); } --- 96,100 ---- inline void reverse_copy(const BidirectionalRange& range, OutputIterator result) { ! std::reverse_copy(boost::begin(range), boost::end(range), result); } Index: assign.hpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/algorithm/assign.hpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** assign.hpp 6 Jan 2006 18:02:35 -0000 1.1 --- assign.hpp 3 Feb 2006 18:33:35 -0000 1.2 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 29,35 **** T& assign(const T& x, T& y) { ! T tmp(x); ! adobe::adl_swap(tmp, y); ! return y; } --- 29,35 ---- T& assign(const T& x, T& y) { ! T tmp(x); ! adobe::adl_swap(tmp, y); ! return y; } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:00
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/md5 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/md5 Modified Files: check_md5.cpp main.cpp md5_smoke.sh Log Message: asl 1.0.13 Index: md5_smoke.sh =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/md5/md5_smoke.sh,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** md5_smoke.sh 3 Jun 2005 16:36:58 -0000 1.1 --- md5_smoke.sh 3 Feb 2006 18:33:39 -0000 1.2 *************** *** 2,11 **** if [ "$1" == "" ]; then ! echo "usage: $0 [ file ]" ! echo " compares the ASL MD5 hash function with OpenSSL MD5." ! echo " Note: you must have the md5_asl binaries compiled" ! echo " before you can use this smoke test." ! exit 1; fi --- 2,11 ---- if [ "$1" == "" ]; then ! echo "usage: $0 [ file ]" ! echo " compares the ASL MD5 hash function with OpenSSL MD5." ! echo " Note: you must have the md5_asl binaries compiled" ! echo " before you can use this smoke test." ! exit 1; fi *************** *** 16,41 **** for TEST_EXE in "./bindebug/md5_asl" "./bin/md5_asl" ; do ! if [ -x $TEST_EXE ]; then ! TEST_RESULT=`$TEST_EXE $1` ! ! if [ "$OPENSSL_RESULT" == "$TEST_RESULT" ]; then ! echo "##### PASS ##### ($TEST_EXE)" ! else ! echo "##### FAIL ##### ($TEST_EXE)" ! fi ! echo " ASL: $TEST_RESULT" ! else ! echo "##### NO TEST ##### ($TEST_EXE)" ! echo " Executable '$TEST_EXE' could not be found and was not tested" ! fi done --- 16,41 ---- for TEST_EXE in "./bindebug/md5_asl" "./bin/md5_asl" ; do ! if [ -x $TEST_EXE ]; then ! TEST_RESULT=`$TEST_EXE $1` ! ! if [ "$OPENSSL_RESULT" == "$TEST_RESULT" ]; then ! echo "##### PASS ##### ($TEST_EXE)" ! else ! echo "##### FAIL ##### ($TEST_EXE)" ! fi ! echo " ASL: $TEST_RESULT" ! else ! echo "##### NO TEST ##### ($TEST_EXE)" ! echo " Executable '$TEST_EXE' could not be found and was not tested" ! fi done Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/md5/main.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** main.cpp 6 Jan 2006 18:03:03 -0000 1.2 --- main.cpp 3 Feb 2006 18:33:39 -0000 1.3 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 20,74 **** int main(int argc, char* argv[]) { ! if (argc <= 1) ! { ! std::cout << "usage: " << argv[0] << " [ file ]" << std::endl; ! std::cout << " generate the MD5 hash of a file" << std::endl; ! std::cout << " Adobe Source Libraries v" << ADOBE_VERSION_MAJOR << "." << ADOBE_VERSION_MINOR << "." << ADOBE_VERSION_SUBMINOR << std::endl; ! std::cout << " Boost v" << BOOST_VERSION / 100000 << "." << BOOST_VERSION / 100 % 1000 << "." << BOOST_VERSION % 100 << std::endl; ! return 1; ! } ! bool success(false); ! try ! { ! adobe::md5_t m; ! boost::filesystem::path file_path(argv[1], boost::filesystem::native); ! std::ifstream stream(file_path.native_file_string().c_str(), std::ios::binary | std::ios::in); ! while (stream.good()) ! { ! boost::array<std::ifstream::char_type, 256*1024> buffer; ! stream.read(&buffer[0], static_cast<std::streamsize>(buffer.size())); ! std::streamsize gcount(stream.gcount()); ! if (gcount > 0) m.update(&buffer[0], static_cast<std::size_t>(gcount)); ! } ! adobe::md5_t::digest_t hash(m.final()); ! adobe::md5_t::digest_t::iterator first(hash.begin()); ! adobe::md5_t::digest_t::iterator last(hash.end()); ! std::cout << "MD5(" << argv[1] << ")= "; ! for(; first != last; ++first) ! { ! std::cout.width(2); ! std::cout.fill('0'); ! std::cout << std::hex << static_cast<int>(*first); ! } ! std::cout << std::endl; ! success = true; ! } ! catch( const std::exception& error ) ! { std::cerr << "Exception: " << error.what() << std::endl; } ! catch( ... ) ! { std::cerr << "Unknown exception" << std::endl; } ! return success ? 0 : 1; } --- 20,74 ---- int main(int argc, char* argv[]) { ! if (argc <= 1) ! { ! std::cout << "usage: " << argv[0] << " [ file ]" << std::endl; ! std::cout << " generate the MD5 hash of a file" << std::endl; ! std::cout << " Adobe Source Libraries v" << ADOBE_VERSION_MAJOR << "." << ADOBE_VERSION_MINOR << "." << ADOBE_VERSION_SUBMINOR << std::endl; ! std::cout << " Boost v" << BOOST_VERSION / 100000 << "." << BOOST_VERSION / 100 % 1000 << "." << BOOST_VERSION % 100 << std::endl; ! return 1; ! } ! bool success(false); ! try ! { ! adobe::md5_t m; ! boost::filesystem::path file_path(argv[1], boost::filesystem::native); ! std::ifstream stream(file_path.native_file_string().c_str(), std::ios::binary | std::ios::in); ! while (stream.good()) ! { ! boost::array<std::ifstream::char_type, 256*1024> buffer; ! stream.read(&buffer[0], static_cast<std::streamsize>(buffer.size())); ! std::streamsize gcount(stream.gcount()); ! if (gcount > 0) m.update(&buffer[0], static_cast<std::size_t>(gcount)); ! } ! adobe::md5_t::digest_t hash(m.final()); ! adobe::md5_t::digest_t::iterator first(hash.begin()); ! adobe::md5_t::digest_t::iterator last(hash.end()); ! std::cout << "MD5(" << argv[1] << ")= "; ! for(; first != last; ++first) ! { ! std::cout.width(2); ! std::cout.fill('0'); ! std::cout << std::hex << static_cast<int>(*first); ! } ! std::cout << std::endl; ! success = true; ! } ! catch( const std::exception& error ) ! { std::cerr << "Exception: " << error.what() << std::endl; } ! catch( ... ) ! { std::cerr << "Unknown exception" << std::endl; } ! return success ? 0 : 1; } Index: check_md5.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/md5/check_md5.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** check_md5.cpp 3 Jun 2005 16:36:57 -0000 1.1 --- check_md5.cpp 3 Feb 2006 18:33:39 -0000 1.2 *************** *** 14,76 **** int main(int argc, char* argv[]) { ! if (argc != 3) { ! std::cout << "usage: " << argv[0] << " hash file " << std::endl; ! std::cout << " check the MD5 hash of a file" << std::endl; ! std::cout << " Adobe Source Libraries v" << ADOBE_VERSION_MAJOR ! << "." << ADOBE_VERSION_MINOR << "." << ADOBE_VERSION_SUBMINOR << std::endl; ! std::cout << " Boost v" << BOOST_VERSION / 100000 << "." << BOOST_VERSION / 100 % 1000 ! << "." << BOOST_VERSION % 100 << std::endl; ! ! return 1; ! } ! bool success = false; ! try ! { ! adobe::md5_t m; ! boost::filesystem::path file_path(argv[2], boost::filesystem::native); ! boost::filesystem::ifstream stream(file_path, std::ios::binary | std::ios::in); ! while (stream.good()) ! { ! boost::array<std::ifstream::char_type, 256*1024> buffer; ! stream.read(&buffer[0], static_cast<std::streamsize>(buffer.size())); ! std::streamsize gcount(stream.gcount()); ! if (gcount > 0) m.update(&buffer[0], static_cast<std::size_t>(gcount)); ! } ! adobe::md5_t::digest_t hash(m.final()); ! adobe::md5_t::digest_t::iterator first(hash.begin()); ! adobe::md5_t::digest_t::iterator last(hash.end()); ! std::string actual; ! std::ostringstream oss(actual); ! for(; first != last; ++first){ ! oss.width(2); ! oss << std::hex << std::setw(2) << std::setfill('0') << static_cast<int>(*first); ! } ! ! std::string expected(argv[1]); ! std::string::iterator e(expected.begin()); ! success = oss.str() == expected; ! if(!success) ! std::cout << "Expected: " << expected ! << " actual: " << oss.str() << std::endl; ! ! } ! catch( const std::exception& error ) ! { ! std::cerr << "Exception: " << error.what() << std::endl; ! } ! catch( ... ) ! { ! std::cerr << "Unknown exception" << std::endl; ! } ! return success ? 0 : 1; } --- 14,76 ---- int main(int argc, char* argv[]) { ! if (argc != 3) { ! std::cout << "usage: " << argv[0] << " hash file " << std::endl; ! std::cout << " check the MD5 hash of a file" << std::endl; ! std::cout << " Adobe Source Libraries v" << ADOBE_VERSION_MAJOR ! << "." << ADOBE_VERSION_MINOR << "." << ADOBE_VERSION_SUBMINOR << std::endl; ! std::cout << " Boost v" << BOOST_VERSION / 100000 << "." << BOOST_VERSION / 100 % 1000 ! << "." << BOOST_VERSION % 100 << std::endl; ! ! return 1; ! } ! bool success = false; ! try ! { ! adobe::md5_t m; ! boost::filesystem::path file_path(argv[2], boost::filesystem::native); ! boost::filesystem::ifstream stream(file_path, std::ios::binary | std::ios::in); ! while (stream.good()) ! { ! boost::array<std::ifstream::char_type, 256*1024> buffer; ! stream.read(&buffer[0], static_cast<std::streamsize>(buffer.size())); ! std::streamsize gcount(stream.gcount()); ! if (gcount > 0) m.update(&buffer[0], static_cast<std::size_t>(gcount)); ! } ! adobe::md5_t::digest_t hash(m.final()); ! adobe::md5_t::digest_t::iterator first(hash.begin()); ! adobe::md5_t::digest_t::iterator last(hash.end()); ! std::string actual; ! std::ostringstream oss(actual); ! for(; first != last; ++first){ ! oss.width(2); ! oss << std::hex << std::setw(2) << std::setfill('0') << static_cast<int>(*first); ! } ! ! std::string expected(argv[1]); ! std::string::iterator e(expected.begin()); ! success = oss.str() == expected; ! if(!success) ! std::cout << "Expected: " << expected ! << " actual: " << oss.str() << std::endl; ! ! } ! catch( const std::exception& error ) ! { ! std::cerr << "Exception: " << error.what() << std::endl; ! } ! catch( ... ) ! { ! std::cerr << "Unknown exception" << std::endl; ! } ! return success ? 0 : 1; } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:00
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/zuidgen In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/adobe/test/zuidgen Modified Files: main.cpp Log Message: asl 1.0.13 Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/adobe/test/zuidgen/main.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** main.cpp 6 Jan 2006 18:03:05 -0000 1.4 --- main.cpp 3 Feb 2006 18:33:40 -0000 1.5 *************** *** 1,6 **** /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ --- 1,6 ---- /* ! Copyright 2005-2006 Adobe Systems Incorporated ! Distributed under the MIT License (see accompanying file LICENSE_1_0_0.txt ! or a copy at http://opensource.adobe.com/licenses.html) */ *************** *** 22,34 **** int main(int argc, char** /*argv*/) { ! if (argc > 1) ! { ! std::cout << "usage: zuidgen" << std::endl; ! std::cout << " generate a ZUID" << std::endl; ! } ! else ! { ! std::cout << adobe::zuid_t().c_str() << std::endl; ! } ! return 0; } --- 22,34 ---- int main(int argc, char** /*argv*/) { ! if (argc > 1) ! { ! std::cout << "usage: zuidgen" << std::endl; ! std::cout << " generate a ZUID" << std::endl; ! } ! else ! { ! std::cout << adobe::zuid_t().c_str() << std::endl; ! } ! return 0; } |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:00
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/ide_projects/darwin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/ide_projects/darwin Modified Files: adobe_all.xcconfig Log Message: asl 1.0.13 Index: adobe_all.xcconfig =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/ide_projects/darwin/adobe_all.xcconfig,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** adobe_all.xcconfig 6 Jan 2006 18:03:05 -0000 1.1 --- adobe_all.xcconfig 3 Feb 2006 18:33:40 -0000 1.2 *************** *** 1,3 **** ! ARCHS = i386 ppc GCC_DYNAMIC_NO_PIC = NO GCC_ENABLE_FIX_AND_CONTINUE = NO --- 1,3 ---- ! ARCHS = ppc GCC_DYNAMIC_NO_PIC = NO GCC_ENABLE_FIX_AND_CONTINUE = NO *************** *** 10,13 **** PREBINDING = NO // doesn't work for 10.4.x SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk ! WARNING_CFLAGS = -Wno-long-double ZERO_LINK = NO --- 10,13 ---- PREBINDING = NO // doesn't work for 10.4.x SDKROOT = /Developer/SDKs/MacOSX10.4u.sdk ! WARNING_CFLAGS = -Wall -Wno-long-double ZERO_LINK = NO |
From: Foster B. <fos...@us...> - 2006-02-03 18:34:00
|
Update of /cvsroot/adobe-source/sandbox/adobe-source/stationery/asl_client_stationery In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6755/stationery/asl_client_stationery Modified Files: info.plist main.cpp version.plist Log Message: asl 1.0.13 Index: info.plist =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/stationery/asl_client_stationery/info.plist,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** info.plist 8 Aug 2005 17:01:54 -0000 1.1 --- info.plist 3 Feb 2006 18:33:41 -0000 1.2 *************** *** 3,24 **** <plist version="1.0"> <dict> ! <key>CFBundleDevelopmentRegion</key> ! <string>English</string> ! <key>CFBundleExecutable</key> ! <string>ASLClientStationery</string> ! <key>CFBundleIconFile</key> ! <string></string> ! <key>CFBundleIdentifier</key> ! <string>com.apple.myCarbonApp</string> ! <key>CFBundleInfoDictionaryVersion</key> ! <string>6.0</string> ! <key>CFBundlePackageType</key> ! <string>APPL</string> ! <key>CFBundleSignature</key> ! <string>????</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>CSResourcesFileMapped</key> ! <true/> </dict> </plist> --- 3,24 ---- <plist version="1.0"> <dict> ! <key>CFBundleDevelopmentRegion</key> ! <string>English</string> ! <key>CFBundleExecutable</key> ! <string>ASLClientStationery</string> ! <key>CFBundleIconFile</key> ! <string></string> ! <key>CFBundleIdentifier</key> ! <string>com.apple.myCarbonApp</string> ! <key>CFBundleInfoDictionaryVersion</key> ! <string>6.0</string> ! <key>CFBundlePackageType</key> ! <string>APPL</string> ! <key>CFBundleSignature</key> ! <string>????</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>CSResourcesFileMapped</key> ! <true/> </dict> </plist> Index: main.cpp =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/stationery/asl_client_stationery/main.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** main.cpp 8 Aug 2005 17:01:54 -0000 1.1 --- main.cpp 3 Feb 2006 18:33:41 -0000 1.2 *************** *** 12,15 **** #endif { ! return 0; } \ No newline at end of file --- 12,15 ---- #endif { ! return 0; } \ No newline at end of file Index: version.plist =================================================================== RCS file: /cvsroot/adobe-source/sandbox/adobe-source/stationery/asl_client_stationery/version.plist,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** version.plist 8 Aug 2005 17:01:54 -0000 1.1 --- version.plist 3 Feb 2006 18:33:41 -0000 1.2 *************** *** 3,16 **** <plist version="1.0"> <dict> ! <key>BuildVersion</key> ! <string>92</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>ProductBuildVersion</key> ! <string>7K571</string> ! <key>ProjectName</key> ! <string>NibPBTemplates</string> ! <key>SourceVersion</key> ! <string>1200000</string> </dict> </plist> --- 3,16 ---- <plist version="1.0"> <dict> ! <key>BuildVersion</key> ! <string>92</string> ! <key>CFBundleVersion</key> ! <string>1.0</string> ! <key>ProductBuildVersion</key> ! <string>7K571</string> ! <key>ProjectName</key> ! <string>NibPBTemplates</string> ! <key>SourceVersion</key> ! <string>1200000</string> </dict> </plist> |